@@ -0,0 +1,1398 @@
+/* %0A* @Author: Zeyuan Shang%0A* @Date:   2015-12-22 17:08:54%0A* @Last Modified by:   Zeyuan Shang%0A* @Last Modified time: 2015-12-22 17:09:05%0A*/%0A%0Aimport java.io.*;%0Aimport java.util.*;%0A%0Aclass Player%7B%0A    String name;%0A    int score;%0A%7D%0A%0Aclass Checker%7B%0A    Comparator%3CPlayer%3E desc;%0A    Checker()%7Bdesc=new Inner();%7D%0A%0A    class Inner implements Comparator%3CPlayer%3E%7B%0A        @Override%0A        public int compare(Player arg0,Player arg1)%7B%0A                int c=Integer.valueOf(arg0.score).compareTo(arg1.score);%0A                if(c!=0)return -c;%0A                return -arg0.name.compareTo(arg1.name);%0A        %7D%0A    %7D%0A%7D%0A%0Aclass Solution%7B%0A    public static void main(String%5B%5D args) throws NumberFormatException, IOException %7B%0A        BufferedReader br=new BufferedReader(new InputStreamReader(System.in));%0A%0A        int N=Integer.parseInt(br.readLine().trim());%0A        String s;%0A        StringTokenizer st;%0A        Player Player%5B%5D=new Player%5BN%5D;%0A        Checker check=new Checker();%0A        for(int i=0;i%3CN;i++)%7B%0A            s=br.readLine().trim();%0A            st=new StringTokenizer(s);%0A            Player%5Bi%5D=new Player();%0A            Player%5Bi%5D.name=st.nextToken();%0A            Player%5Bi%5D.score=Integer.parseInt(st.nextToken());%0A        %7D%0A%0A        Arrays.sort(Player,check.desc);%0A        for(int i=0;i%3CPlayer.length;i++)%7B%0A            System.out.printf(%22%25s %25s%5Cn%22,Player%5Bi%5D.name,Player%5Bi%5D.score);%0A        %7D%0A    %7D%0A%7D

add java-comparator