Ad
  • Custom User Avatar

    I tested it, it worked for sure:

        public static void main(String[] args) {
            String str = "hellllllloooo";
            System.out.println(clever(str));
            String str1 = "hi";
            System.out.println(clever(str1));
            String str2 = "";
            System.out.println(clever(str2));
    
        }
     
     #########oooo
    hi