import java.util.*; public class Main { static List<String> list = null; public static void main(String[] args) { Scanner sc = new Scanner(System.in); while(sc.hasNext()){ list = new ArrayList<>(); String l1 = sc.next(); String...