import java.util.Scanner; public class C { public static void main(String[] args){ Scanner sc=new Scanner(System.in); String[] str=sc.nextLine().replaceAll(" ","").replaceAll(" ","").split(""); int n[][]=new int[str.length][str.length]; ...