@@ -0,0 +1,942 @@
+import java.util.Scanner;%0A%0Apublic class Main %7B%0A%0A    public static void main(String%5B%5D args) %7B%0A%0A        Scanner sc = new Scanner(System.in);%0A%0A        String%5B%5D words = sc.nextLine().split(%22 %22);%0A%0A        int%5B%5D wordsCount = new int%5Bwords.length%5D;%0A%0A        int letterMax = 0;%0A        int letterMaxIdx = 0;%0A%0A        for (int i = 0; i %3C words.length; i++) %7B%0A%0A            if (letterMax %3C words%5Bi%5D.length()) %7B%0A                letterMax = words%5Bi%5D.length();%0A                letterMaxIdx = i;%0A            %7D%0A%0A            for (int j = i; j %3C words.length; j++) %7B%0A%0A                if (words%5Bi%5D.equals(words%5Bj%5D)) %7B%0A                    wordsCount%5Bj%5D++;%0A                %7D%0A%0A            %7D%0A%0A        %7D%0A%0A        int wordMax = 0;%0A%0A        for (int i = 0; i %3C wordsCount.length; i++) %7B%0A%0A            if (wordMax %3C wordsCount%5Bi%5D) %7B%0A                wordMax = i;%0A            %7D%0A%0A        %7D%0A%0A        System.out.println(words%5BwordMax%5D + %22 %22 + words%5BletterMaxIdx%5D);%0A%0A    %7D%0A%0A%7D%0A

Create : 0029