整理音乐(SDUT 2053) import java.util.*; public class Main { public static void main(String[] args) { Scanner reader=new Scanner(System.in); int n=reader.nextInt(); String string[] =new String[10001]; int A[]=new int [10001]; int flag=0; for(int i=1;i<=n;…