node_ids
listlengths
4
1.4k
edge_index
listlengths
1
2.22k
text
listlengths
4
1.4k
source
stringlengths
14
427k
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 2, 18, 13, 13, 17, 1, 40, 13, 30, 30,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 123, 5 ], [ 123, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\npublic class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint[] mtn = new int[10];\n\t\tfor(int i = 0; i<mtn.length; i++){\n\t\t\tmtn[i] = sc.nextInt();\n\t\t}\n\t\tfor(int i = 0; i<mtn.length-1; i++){\n\t\t\tfor(int j = i+1; j<mtn.lengt...
import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); int[] mtn = new int[10]; for(int i = 0; i<mtn.length; i++){ mtn[i] = sc.nextInt(); } for(int i = 0; i<mtn.length-1; i++){ for(int j = i+1; j<mtn.length; j++){ if(mtn[i] < mtn[j]){ int tmp; tmp = mtn[i]; mtn[i] = mtn[j]; mtn[j] = tmp; } } } for(int i = 0; i<3; i++) System.out.println(mtn[i]); } }
[ 7, 15, 13, 17, 6, 13, 41, 13, 20, 12, 13, 30, 20, 23, 13, 12, 13, 30, 4, 18, 20, 6, 13, 12, 13, 30, 41, 13, 20, 42, 4, 18, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 2, 4, 18, 13, 17, 2, 13, 2, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 73, 5 ], [ 73, 6 ], [ 6, 7 ], [ 6, 8 ], [ 73, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 9, 13 ], [ 13, 14 ], ...
[ "import java.util.*;\n\npublic class Main {\n Scanner in = new Scanner(System.in);\n public static void main(String[] args) {\n new Main();\n }\n\n public Main(){\n \tnew AOJ().doIt();\n }\n \n class AOJ{\n \tvoid doIt(){\n \t\tArrayList<Integer> list = new ArrayList<Integer>();...
import java.util.*; public class Main { Scanner in = new Scanner(System.in); public static void main(String[] args) { new Main(); } public Main(){ new AOJ().doIt(); } class AOJ{ void doIt(){ ArrayList<Integer> list = new ArrayList<Integer>(); while(in.hasNext())list.add(in.nextInt()); Collections.sort(list); for(int i=list.size()-1;i>=list.size()-3;i--)System.out.println(list.get(i)); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 123, 5 ], [ 123, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.io.*;\n\npublic class Main{\n public static void main(String[]args)throws IOException{\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n int[] data = new int[10];\n\n for(int i=0; i<10; i++){\n data[i] = Integer.parseInt(br.readLine());\n ...
import java.io.*; public class Main{ public static void main(String[]args)throws IOException{ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int[] data = new int[10]; for(int i=0; i<10; i++){ data[i] = Integer.parseInt(br.readLine()); } for(int i=0; i<3; i++){ int maxIndex = i; for(int k=i+1; k<10; k++){ if(data[maxIndex] < data[k]){ maxIndex = k; } } int tmp = data[maxIndex]; data[maxIndex] = data[i]; data[i] = tmp; } for(int i=0; i<3; i++){ System.out.println(data[i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 17, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 41, 13, 18...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 128, 5 ], [ 128, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) throws Exception {\n Scanner sc = new Scanner(System.in);\n int n = 10;\n int[] ary = new int[n];\n for (int i = 0; i < n; i++) {\n ary[i] = sc.nextInt();\n }\n \n ...
import java.util.Scanner; public class Main { public static void main(String[] args) throws Exception { Scanner sc = new Scanner(System.in); int n = 10; int[] ary = new int[n]; for (int i = 0; i < n; i++) { ary[i] = sc.nextInt(); } for (int i = 1; i < n; i++) { int value = ary[i]; for (int j = i-1;; j--) { if (j < 0) { break; } if (ary[j] >= value) { ary[j+1] = value; break; } ary[j+1] = ary[j]; ary[j] = value; } } for (int i = 0; i < 3; i++) { System.out.println(ary[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 13, 13, 4, 18, 13, 13, 11, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\n\nclass Main {\n\n\tpublic static void main(String[] args) {\n\n\t\t// ストリームを作成する\n\t\tBufferedReader reader = new BufferedReader(new I...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; import java.util.List; class Main { public static void main(String[] args) { // ストリームを作成する BufferedReader reader = new BufferedReader(new InputStreamReader( System.in)); // 入力値を受け取り、リストに追加する List<Integer> heightList = new ArrayList<Integer>(); for (int i = 0; i < 10; i++) { heightList.add(getHeight(reader)); } // 昇順にソートする Collections.sort(heightList); // 下位3件を出力する for (int i = 0; i < 3; i++) { System.out.println(heightList.get(9 - i)); } } /** * ストリームから1行読み込んで、高さを数値として返す。 * * @param reader * 入力ストリーム * @return 高さ */ private static Integer getHeight(BufferedReader reader) { Integer height = null; try { String line = reader.readLine(); height = new Integer(line); } catch (IOException e) { throw new RuntimeException(); } return height; } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 38, 5, 13, 30, 30, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 13, 14, 2, 2, 13, 17, 2, 13, 17, 30, 0, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 13, 14 ], [...
[ "import java.io.*;\n\nclass Main{\n public static void main(String[] a){\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n try{\n int[] mount = new int [10];\n for(int i = 0;i < 10;i++){\n String str = br.readLine();\n ...
import java.io.*; class Main{ public static void main(String[] a){ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); try{ int[] mount = new int [10]; for(int i = 0;i < 10;i++){ String str = br.readLine(); int high = Integer.parseInt(str); if(high >= 0 && high <= 10000){ mount[i] = high; } for(int k = 0;k <= i; k++){ if(mount[k] < mount[i]){ int h = mount[i]; mount[i] = mount[k]; mount[k] = h; } } } for(int j = 0;j < 3; j++){ System.out.println(mount[j]); } } catch(IOException e){ } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 14, 2, 18, 13, 13, 13, 30, 0, 13, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 111, 5 ], [ 111, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\n\n\npublic class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint a=0,b=0,c =0;\n\t\tint[] n= new int[10];\n\t\tfor(int i=0;i<10;i++){\n\t\t\tn[i]=sc.nextInt();\n\t\t\tif(n[i]>a){\n\t\t\t\tc=b;\n\t\t\t\tb=a;\n\t\t\t\ta=n[i];\n\t\t\t}els...
import java.util.Scanner; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); int a=0,b=0,c =0; int[] n= new int[10]; for(int i=0;i<10;i++){ n[i]=sc.nextInt(); if(n[i]>a){ c=b; b=a; a=n[i]; }else if(n[i]>b){ c=b; b=n[i]; }else if(n[i]>c){ c=n[i]; } } System.out.println(a); System.out.println(b); System.out.println(c); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 4, 18...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner scan=new Scanner(new BufferedReader(new InputStreamReader(System.in)));\n\t\tArr...
import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan=new Scanner(new BufferedReader(new InputStreamReader(System.in))); ArrayList<Integer> list=new ArrayList<Integer>(); for (int i = 0; i < 10; i++) { list.add(scan.nextInt()); } Collections.sort(list,Collections.reverseOrder()); System.out.println(list.get(0)); System.out.println(list.get(1)); System.out.println(list.get(2)); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 17, 41, 13, 20, 17, 41, 13, 42, 2, 0, 13, 4, 18, 13, 17, 30, 0, 18, 13, 40, 13, 4, 18, 13, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.*;\nimport java.util.*;\nimport java.lang.*;\n\nimport static java.util.Arrays.*;\nimport static java.util.Collections.reverseOrder;\n\n/**\n * Created by locona on 2016/06/02.\n */\npublic class Main {\n public static void main(String[] args) throws IOException {\n BufferedReader br = ne...
import java.io.*; import java.util.*; import java.lang.*; import static java.util.Arrays.*; import static java.util.Collections.reverseOrder; /** * Created by locona on 2016/06/02. */ public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); PrintWriter out = new PrintWriter(System.out); int i = 0; Integer [] mountains = new Integer[10]; String line; while((line = br.readLine()) != null) { mountains[i++] = Integer.valueOf(line); if(i >= 10) break; } sort(mountains, Comparator.reverseOrder()); for(i=0; i < 3; i++) { out.println(mountains[i]); } out.flush(); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 17, 41, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.*;\nimport java.util.*;\n \nclass Main{\npublic static void main(String[] args) throws IOException{\nBufferedReader br=new BufferedReader(new InputStreamReader(System.in));\nint n=10;\nint[] k=new int[n];\nfor(int i=0;i<n;i++){\nk[i]=Integer.parseInt(br.readLine());\n}\nArrays.sort(k);\nfor(int i...
import java.io.*; import java.util.*; class Main{ public static void main(String[] args) throws IOException{ BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); int n=10; int[] k=new int[n]; for(int i=0;i<n;i++){ k[i]=Integer.parseInt(br.readLine()); } Arrays.sort(k); for(int i=0;i<3;i++){ System.out.println(k[n-i-1]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, 0, 18, 13, 13, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\nimport java.util.Collections;\n\npublic class Main {\n\n\tpublic static void main(String[] args) throws NumberFormatException, IOException {\n\t\tBufferedReader sb = new BufferedReader(new Inpu...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; import java.util.Collections; public class Main { public static void main(String[] args) throws NumberFormatException, IOException { BufferedReader sb = new BufferedReader(new InputStreamReader(System.in)); Integer[] hList = new Integer[10]; for (int num = 0; num < 10; num++) { int h = Integer.parseInt(sb.readLine()); hList[num] = h; } Arrays.sort(hList, Collections.reverseOrder()); for (int rank = 0; rank < 3; rank++) { System.out.println(hList[rank]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 20, 13, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 20, 41, 13, 41, 13, 17, 38, 5, 13, 30, 30, 42, 2, 2, 2, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\n\nclass Main {\n\n\tpublic static void main (String [] a){\n\n\t\tint numMountain = 10;\n\t\tint minConst = 0;\n\t\tint maxConst = 10000;\n\t\tint[] mountainList = new int[numMountain];\n\t\tint topOne = 0;\n\t\tint top...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; class Main { public static void main (String [] a){ int numMountain = 10; int minConst = 0; int maxConst = 10000; int[] mountainList = new int[numMountain]; int topOne = 0; int topTwo = 0; int topThree = 0; BufferedReader stdin = new BufferedReader(new InputStreamReader(System.in)); String line; int i = 0; try { while (i < numMountain && (line = stdin.readLine()) != null && line.length()!= 0 ) { try { int tempHeight = Integer.parseInt(line); if (tempHeight < minConst || tempHeight > maxConst) { } else { mountainList[i] = tempHeight; i++; } } catch (NumberFormatException e){ // TODO Auto-generated catch block //e.printStackTrace(); } } for (int j=0; j<numMountain; j++){ if (mountainList[j] >= topOne){ topThree = topTwo; topTwo = topOne; topOne = mountainList[j]; } else if (mountainList[j] >= topTwo){ topThree = topTwo; topTwo = mountainList[j]; } else if (mountainList[j] >= topThree){ topThree = mountainList[j]; } } System.out.println(topOne +"\n"+ topTwo +"\n"+ topThree); } catch (IOException e) { // TODO Auto-generated catch block //e.printStackTrace(); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\n\npublic class Main {\n\n\tpublic static void main(String[] args) throws NumberFormatException, IOException {\n\t\tBufferedReader br=new BufferedReader(new Inp...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; public class Main { public static void main(String[] args) throws NumberFormatException, IOException { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); ArrayList<Integer> list=new ArrayList<Integer>(); for (int i = 0; i < 10; i++) { list.add(Integer.parseInt(br.readLine())); } Collections.sort(list); for (int i = 9; i > 6; i--) { System.out.println(list.get(i)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 41, 13, 2, 18, 13, 13, 17, 42, 2...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 75, 11 ], [ 75, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "\nimport java.util.Arrays;\nimport java.util.Comparator;\nimport java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args){\n\t\tint[] input = new int[10];\n\t\tScanner s = new Scanner(System.in);\n\t\tfor(int i=0; i<10; i++){\n\t\t\t//System.out.println(\"Please input the \"+ (i+1) +\"th...
import java.util.Arrays; import java.util.Comparator; import java.util.Scanner; public class Main { public static void main(String[] args){ int[] input = new int[10]; Scanner s = new Scanner(System.in); for(int i=0; i<10; i++){ //System.out.println("Please input the "+ (i+1) +"th number(integer)"); input[i]=s.nextInt(); } Arrays.sort(input); int i=input.length-1; while(i>input.length-4){ System.out.println(input[i]); i--; } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 39, 17, 17, 17, 41, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 13, 4, 18, 13, 0, 13, 4, 18, 13, 13, 13, 4, 18, 18, 13, 13, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 160, 5 ], [ 160, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tCalc calc = new Calc();\n\t\tint[] height = {0,0,0};\n\t\tint newh;\n\t\t;\n\t\tfor(int cnt = 0;cnt<10;cnt++){\n\t\t\tnewh = sc.nextInt();\n\t\t\theight = Calc.calc(newh, heigh...
import java.util.Scanner; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); Calc calc = new Calc(); int[] height = {0,0,0}; int newh; ; for(int cnt = 0;cnt<10;cnt++){ newh = sc.nextInt(); height = Calc.calc(newh, height); }; System.out.println(height[0]); System.out.println(height[1]); System.out.println(height[2]); } } class Calc{ //private static final int imax = 110; public static int[] calc(int h, int[] Pastheight){ int Newheight[] = (int[])Pastheight.clone(); if( (h > Pastheight[2]) && (h <= Pastheight[1])){ Newheight[2] = h; }else if((h > Pastheight[1]) && (h <= Pastheight[0])){ Newheight[1] = h; Newheight[2] = Pastheight[1]; }else if(h > Pastheight[0]){ Newheight[0] = h; Newheight[1] = Pastheight[0]; Newheight[2] = Pastheight[1]; } return Newheight; } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 80, 14 ], ...
[ "\nimport java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\n\npublic class Main {\n\n public static void main(String[] args) throws IOException {\n BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));\n\n int[] hillHeig...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; public class Main { public static void main(String[] args) throws IOException { BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); int[] hillHeights = new int[10]; //Input. for (int i = 0; i < 10; i++) hillHeights[i] = Integer.parseInt(reader.readLine()); //Sort. Arrays.sort(hillHeights); //Output. for (int i = 0; i < 3; i++) System.out.println(hillHeights[hillHeights.length - i - 1]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.text.ParseException;\nimport java.util.Arrays;\nimport java.util.Collections;\n\nclass Main{\n\tpublic static void main(String[] a)throws ParseException , IOException{\n\t\tBufferedReader br = new BufferedRe...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.text.ParseException; import java.util.Arrays; import java.util.Collections; class Main{ public static void main(String[] a)throws ParseException , IOException{ BufferedReader br = new BufferedReader(new InputStreamReader(System.in )); Integer[] mountainHeight = new Integer[10]; for (int i = 0 ; i <= 9 ; i++) { mountainHeight[i] = Integer.valueOf(br.readLine()); } Arrays.sort(mountainHeight , Collections.reverseOrder()); for(int i = 0; i < 3 ; i++){ System.out.println(mountainHeight[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\n\nclass Main {\n public static void main(String[] args) throws IOException {\n ArrayList<Integer> array = new ArrayList<Integer>();\n BufferedReader buf...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; class Main { public static void main(String[] args) throws IOException { ArrayList<Integer> array = new ArrayList<Integer>(); BufferedReader buf = new BufferedReader(new InputStreamReader(System.in)); for(int i = 0; i < 10; i++) { int x = Integer.valueOf(buf.readLine()); array.add(x); } Collections.sort(array); Collections.reverse(array); for(int i = 0; i < 3; i++) { System.out.println(array.get(i)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 4, 13, 4, 13, 13, 23, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 17, 41, 13, 20, 17, 41, 13, 17, 38, 30, 4, 18, 13, 4, 18, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 111, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\n\n/**\n * 0001:List of Top 3 Hills\n * \n * @author Lyu\n * @version 2015/06/21\n */\npublic class Main {\n\n /**\n * 10個のデータを読み込み、高い順に3つ出力する。\n * \n * @param args\n * @throw...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; /** * 0001:List of Top 3 Hills * * @author Lyu * @version 2015/06/21 */ public class Main { /** * 10個のデータを読み込み、高い順に3つ出力する。 * * @param args * @throws IOException * @throws NumberFormatException */ public static void main(String[] args) throws NumberFormatException, IOException { // 標準入力読取り int[] heightOfHills = getHeightOfHills(); // 高い順に3つを表示 printTop3(heightOfHills); } /** * 標準入力を読み取り、山の高さを表すデータを要素数10の配列で返す。 * * @return 山の高さを表す配列 * @throws NumberFormatException * @throws IOException */ private static int[] getHeightOfHills() throws NumberFormatException, IOException { // 入力読取り InputStreamReader streamReader = new InputStreamReader(System.in); BufferedReader bufferedReader = new BufferedReader(streamReader); String line = null; int[] heightOfHills = new int[10]; int count = 0; try { while ((line = bufferedReader.readLine()) != null) { heightOfHills[count] = Integer.parseInt(line); ++count; } } finally { bufferedReader.close(); streamReader.close(); } return heightOfHills; } /** * 受け取ったint型配列要素を、数値の大きい順に3つ出力する。 * * @param array int型の配列 */ private static void printTop3(int[] array) { // ソート Arrays.sort(array); // 高い順に3つを出力 for (int i = 1; i <= 3; ++i) { System.out.println(array[array.length - i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 39, 17, 17, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, 14, 2, 18, 13, 17, 13, 30, 0, 18, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.List;\nimport java.util.Scanner;\n\nclass Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc =new Scanner(System.in);\n\t\tint[] highests={0,0,0};\n\t\tfor(int i=0;i<10;i++){\n\t\t\tint height=Integer.parseInt(sc.nextLine());\n\n\t\t\tif(highests[0]<=heig...
import java.util.ArrayList; import java.util.List; import java.util.Scanner; class Main{ public static void main(String[] args){ Scanner sc =new Scanner(System.in); int[] highests={0,0,0}; for(int i=0;i<10;i++){ int height=Integer.parseInt(sc.nextLine()); if(highests[0]<=height){ highests[2]=highests[1]; highests[1]=highests[0]; highests[0]=height; }else if(highests[1]<=height){ highests[2]=highests[1]; highests[1]=height; }else if(highests[2]<=height){ highests[2]=height; } } System.out.println(highests[0]); System.out.println(highests[1]); System.out.println(highests[2]); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 41, 13, 20, 41, 13, 20, 17, 41, 13, 41, 13, 11, 1, 0, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 0, 13, 17, 2, 13, 17, 1, 40, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 122, 8 ], [ 122, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 11, 14 ]...
[ "\nimport java.io.*;\nimport java.util.Scanner;\npublic class Main {\npublic static void main(String args[])\n{\n\tint j;\n\t//Scanner a = new Scanner(System.in);\n\tScanner in = new Scanner(System.in);\n\t//System.out.println(\"ENter the list\");\n\tint height[]=new int[10];\n\tint i;\n\t//int j;\n\tint x;\n\tfor(...
import java.io.*; import java.util.Scanner; public class Main { public static void main(String args[]) { int j; //Scanner a = new Scanner(System.in); Scanner in = new Scanner(System.in); //System.out.println("ENter the list"); int height[]=new int[10]; int i; //int j; int x; for(i=0;i<10;i++) { height[i]=in.nextInt(); } /*for(i=0;i<10;i++) { System.out.print(height[i]+ " "); } */ for(i=0;i<10;i++) { for(j=i+1;j<10;j++) if(height[i]>height[j]) { int temp=height[i]; height[i]=height[j]; height[j]=temp; } } //System.out.println("Sorted"); for(i=9;i>6;i--) { System.out.println(height[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 17, 41, 13, 17, 41, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 38, 5, 13, 30, 4, 18, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\n\nclass Top3{\n\tint fst=0;\n\tint snd=0;\n\tint thd=0;\n}\n\npublic class Main{\n\tpublic static void main(String args[]){\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\t\n\t\tint m...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; class Top3{ int fst=0; int snd=0; int thd=0; } public class Main{ public static void main(String args[]){ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int mnt[]=new int[10]; for(int i=0;i<10;i++){ String s; try { s = br.readLine(); mnt[i]=Integer.parseInt(s); } catch (IOException e) { e.printStackTrace(); } } Top3 m = new Top3(); for(int i=0;i<10;i++){ if(mnt[i]>m.fst){ m.thd = m.snd; m.snd = m.fst; m.fst = mnt[i]; }else if(mnt[i]>m.snd){ m.thd = m.snd; m.snd = mnt[i]; }else if(mnt[i]>m.thd){ m.thd = mnt[i]; } } System.out.println(m.fst); System.out.println(m.snd); System.out.println(m.thd); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 67, 5 ], [ 67, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 13 ], [ 13, 14 ], [ 13, 15 ], ...
[ "import java.util.*;\n\npublic class Main {\n public static void main(String args[] ) throws Exception {\n Integer arrays[] = new Integer[10];\n\n Scanner sc = new Scanner(System.in);\n for (int i = 0; i < 10; i++){\n arrays[i] = sc.nextInt();\n }\n Arrays.sort(array...
import java.util.*; public class Main { public static void main(String args[] ) throws Exception { Integer arrays[] = new Integer[10]; Scanner sc = new Scanner(System.in); for (int i = 0; i < 10; i++){ arrays[i] = sc.nextInt(); } Arrays.sort(arrays, Comparator.reverseOrder()); for (int i = 0; i < 3; i++) { System.out.println(arrays[i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 41, 13, 0, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 13, 4, 18, 13, 14, 2, 18, 13, 17, 13, 30, 0, 18, 13, 17, 18, 13, 17, 0, 18, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 8, 14 ], [ ...
[ "import java.util.Scanner;\n\nclass Main {\n\tpublic static void main(String[] a){\n\t\tScanner scan = new Scanner(System.in);\n\t\n\t\tint m;\n\t\tint[] tall;\n\t\ttall = new int[3];\n\t\t\n\t\tfor(int i = 0; i < 10; i++){\n\t\t\tm = scan.nextInt();\n\t\t\tif(tall[0] < m){\n\t\t\t\ttall[2] = tall[1];\n\t\t\t\ttall...
import java.util.Scanner; class Main { public static void main(String[] a){ Scanner scan = new Scanner(System.in); int m; int[] tall; tall = new int[3]; for(int i = 0; i < 10; i++){ m = scan.nextInt(); if(tall[0] < m){ tall[2] = tall[1]; tall[1] = tall[0]; tall[0] = m; }else if(tall[1] < m){ tall[2] = tall[1]; tall[1] = m; }else if(tall[2] < m){ tall[2] = m; } } for(int i = 0; i < 3; i++){ System.out.println(tall[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 38, 5, 13, 30, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 81, 11 ], [ 81, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\n\npublic class Main {\n\tpublic static void main(String[] args){\n\t\ttry{\n\t\t\tBufferedReader stdReader = new BufferedReader(new InputStreamReader(System.in));\n\t\t\tint[] num = new int[10];\n\t\t\tfor(int i=0;i<10;i++...
import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; public class Main { public static void main(String[] args){ try{ BufferedReader stdReader = new BufferedReader(new InputStreamReader(System.in)); int[] num = new int[10]; for(int i=0;i<10;i++){ num[i] = Integer.parseInt(stdReader.readLine()); } Arrays.sort(num); System.out.println(num[9]); System.out.println(num[8]); System.out.println(num[7]); }catch(Exception e){ } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 4, 18, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\nclass Main{\n public static void main(String[] a) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamRe...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; import java.util.List; class Main{ public static void main(String[] a) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); List<Integer> iList = new ArrayList<Integer>(); // ???????????? for (int i = 0 ; i < 10; i++) { iList.add(Integer.valueOf(br.readLine())); } // ???????????????????????? Collections.sort(iList); for (int i = iList.size() - 1; i > iList.size() - 4; i--) { System.out.println(iList.get(i)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 69, 8 ], [ 69, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\nimport java.util.Scanner;\n\n/**\n * Created by hwzheng on 2016/12/13.\n */\npublic class Main {\n public static void main(String[] a) {\n Scanner scanner = new Scanner(System.in);\n int[] heights = new int[10];\n for (int i = 0; i < 10; i++){\n heights[...
import java.util.Arrays; import java.util.Scanner; /** * Created by hwzheng on 2016/12/13. */ public class Main { public static void main(String[] a) { Scanner scanner = new Scanner(System.in); int[] heights = new int[10]; for (int i = 0; i < 10; i++){ heights[i] = scanner.nextInt(); } Arrays.sort(heights); for (int i = 0;i <3; i++){ System.out.println(heights[9-i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 11, 1, 41,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 121, 5 ], [ 121, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\npublic class Main{\n\tpublic static void main(String[] args){\n\t\tScanner sc = new Scanner(System.in);\n\t\tint[] h = new int[11];\n\t\tint hz = 0;\n\t\tfor(int i=1; i<=10; i++){\n\t\t\th[i] = sc.nextInt();\n\t\t}\n\t\tfor(int i=9; i>=1; i--){\n\t\t\tfor(int j=1; j<=i; j++){\n\t\t\t\tif...
import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); int[] h = new int[11]; int hz = 0; for(int i=1; i<=10; i++){ h[i] = sc.nextInt(); } for(int i=9; i>=1; i--){ for(int j=1; j<=i; j++){ if(h[j] <= h[j+1]){ hz = h[j+1]; h[j+1] = h[j]; h[j] =hz; } } } for(int i=1; i<=3; i++){ System.out.println(h[i]); } } }
[ 7, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 41, 13, 17, 42, 2, 4, 18, 13, 2, 13, 17, 30, 0, 18, 13, 40, 13, 4, 18, 13, 4, 18, 18, 18, 13, 13, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 3, 4 ], [ 3, 5 ], [ 5, 6 ], [ 6, 7 ], [ 6, 8 ], [ 5, 9 ], [ 9, 10 ], [ 9, 11 ], [ 5, 13 ], [ 13, 14 ], [ 13, 15 ], [...
[ "\nclass Main\n{\n\tpublic static void main(String[] av)\n\t{\n\t\tjava.util.Scanner sc = new java.util.Scanner(System.in);\n\t\tint [] vec = new int[10];\n\t\tint j = 0;\n\t\twhile( sc.hasNextInt() && j < 10 )\n\t\t{\n\t\t\tvec[j++] = ( sc.nextInt() );\t\n\t\t}\n\t\tjava.util.Arrays.sort( vec );\n\t\tfor ( int i =...
class Main { public static void main(String[] av) { java.util.Scanner sc = new java.util.Scanner(System.in); int [] vec = new int[10]; int j = 0; while( sc.hasNextInt() && j < 10 ) { vec[j++] = ( sc.nextInt() ); } java.util.Arrays.sort( vec ); for ( int i = 0; i < 3; ++i ) { System.out.println( vec[9-i] ); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 0, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 18, 13, 13, 18, 13, 17, 4, 18, 18, 13, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 69, 5 ], [ 69, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 8, 14 ], ...
[ "import java.util.*;\npublic class Main {\n\tpublic static void main(String[] args){\n\t Scanner sc= new Scanner (System.in);\n\tint a[];\n\t a = new int[10];\n\t \tfor(int b=0;b<10;b++){\n\t \t\ta[b]=sc.nextInt();\n\t \t}\n\n\t \n\t Arrays.sort (a);\n\tSystem.out.println(a[9]);\n\tSystem.out.println(a[8]);\n\tSys...
import java.util.*; public class Main { public static void main(String[] args){ Scanner sc= new Scanner (System.in); int a[]; a = new int[10]; for(int b=0;b<10;b++){ a[b]=sc.nextInt(); } Arrays.sort (a); System.out.println(a[9]); System.out.println(a[8]); System.out.println(a[7]); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 20, 17, 38, 5, 13, 30, 4, 18, 18, 13, 13, 4, 18, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 0, 18, 13, 13, 4, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 13 ], [ 13, 14 ], [ 13, 15 ], [...
[ "import java.io.*;\nclass Main{\npublic static void main(String[] args){\n\tString[] x = new String[10];\n\tint[] mountain=new int[10];\n\ttry{\n\tInputStreamReader is =new InputStreamReader(System.in);\n\tBufferedReader br = new BufferedReader(is);\n \tfor(int i=0;i<10;i++)\n\t x[i]=br.readLine();\n\t}catc...
import java.io.*; class Main{ public static void main(String[] args){ String[] x = new String[10]; int[] mountain=new int[10]; try{ InputStreamReader is =new InputStreamReader(System.in); BufferedReader br = new BufferedReader(is); for(int i=0;i<10;i++) x[i]=br.readLine(); }catch(IOException e){ System.out.println(e.getMessage()); } for(int i=0;i<10;i++) mountain[i]=Integer.parseInt(x[i]); for(int i=0;i<10;i++) for(int j=1;j<10;j++) if(mountain[j]<mountain[j-1]){ int t=mountain[j]; mountain[j]=mountain[j-1]; mountain[j-1]=t; } for(int i=9;i>6;i--) System.out.println(mountain[i]); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 41, 13, 41, 13, 20, 0, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 122, 5 ], [ 122, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 8, 11 ], [ 11, 12 ], [ 8, 13 ], [ 13, 14 ],...
[ "import java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\t//??????????????°\n\t\tint[] mountain;\n\t\tint taihi;\n\n\t\t//??????\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tmountain = new int[10];\n\t\tfor(int i=0; i<10; i++){\n\t\t\tmountain[i] = sc.nextInt();\n\t\t}...
import java.util.Scanner; public class Main { public static void main(String[] args) { //??????????????° int[] mountain; int taihi; //?????? Scanner sc = new Scanner(System.in); mountain = new int[10]; for(int i=0; i<10; i++){ mountain[i] = sc.nextInt(); } for(int i=0; i<mountain.length; i++){ for(int y = i+1; y<mountain.length; y++){ if(mountain[i]<mountain[y]){ taihi = mountain[i]; mountain[i] = mountain[y]; mountain[y] = taihi; } } } for(int i=0; i<3; i++){ System.out.println(mountain[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\nimport java.util.ArrayList;\nimport java.util.Collections;\n\nclass Main {\n public static void main(String[] args) throws NumberFormatException, IOException {\n ArrayList<Integer> in...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; import java.util.ArrayList; import java.util.Collections; class Main { public static void main(String[] args) throws NumberFormatException, IOException { ArrayList<Integer> input = new ArrayList<Integer>(); BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); for(int i=0; i<10; i++) input.add(Integer.parseInt(br.readLine())); Collections.sort(input, Collections.reverseOrder()); for(int i=0; i<3; i++) System.out.println(input.get(i)); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 134, 8 ], [ 134, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ]...
[ "import java.io.*;\nimport java.util.*;\npublic class Main{\n\tpublic static void main(String[] args) throws IOException{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tint[] yama = new int[10];\n\t\tfor(int i = 0;i <= 9;i++){\n\t\t\tyama[i] = Integer.parseInt(br.readLine());\n\...
import java.io.*; import java.util.*; public class Main{ public static void main(String[] args) throws IOException{ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int[] yama = new int[10]; for(int i = 0;i <= 9;i++){ yama[i] = Integer.parseInt(br.readLine()); } int dami = 0; for(int i = 0;i <= 8; i++){ int x = i; for(int j = i + 1;j <= 9;j++){ if(yama[x] < yama[j]){ x = j; } } if(x != i){ dami = yama[x]; yama[x] = yama[i]; yama[i] = dami; } } for(int i = 0;i <= 2;i++){ System.out.println(yama[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "\nimport java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\n\nclass Main {\n\tpublic static void main(String[] args) throws IOException {\n\t\tArrayList<Integer> heights = new ArrayList<Integer...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; import java.util.List; class Main { public static void main(String[] args) throws IOException { ArrayList<Integer> heights = new ArrayList<Integer>(); InputStreamReader isr = new InputStreamReader(System.in); BufferedReader br = new BufferedReader(isr); for (int i = 0; i < 10; i++) { int h = Integer.parseInt(br.readLine()); heights.add(h); } Collections.sort(heights); Collections.reverse(heights); for (int i = 0; i < 3; i++) { System.out.println(heights.get(i)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 41, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 13, 0, 13, 4, 18, 13, 4, 18, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.*;\nimport java.util.Arrays;\n\nclass Main {\n\tpublic static void main(String[] args) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in),1);\n\t\tint[] arrays = new int[10];\n\t\tString str = br.readLine();\n\t\tfor (int i = 0; i < arrays.length; i++) ...
import java.io.*; import java.util.Arrays; class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in),1); int[] arrays = new int[10]; String str = br.readLine(); for (int i = 0; i < arrays.length; i++) { arrays[i] = Integer.parseInt(str); str = br.readLine(); } Arrays.sort(arrays); for (int i = 1; i <= 3; i++) { System.out.println(arrays[arrays.length - i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 17, 41, 13, 20, 41, 13, 20, 12, 13, 30, 41, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.InputStreamReader;\nimport java.util.ArrayDeque;\nimport java.util.ArrayList;\nimport java.util.Arrays;\nimport java.util.Collections;\nimport java.util.HashMap;\nimport java.util.Stack;\nimport java.util.Scann...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.util.ArrayDeque; import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.HashMap; import java.util.Stack; import java.util.Scanner; import java.util.Queue; /** * @author yoshikyoto */ class Main{ static final boolean DEBUG = false; static Scanner sc = new Scanner(new InputStreamReader(System.in)); static BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); public static void main(String args[]) throws Exception{ int[] m = new int[10]; for(int i = 0; i < 10; i++) m[i] = readInt(); Arrays.sort(m); for(int i = 0; i < 3; i++) p(m[9-i]); } public static String readLine() throws IOException{return br.readLine();} public static int readInt(){return sc.nextInt();} public static void pa(Object[] arr){System.out.println(Arrays.toString(arr));} public static void pa(int[] arr){System.out.println(Arrays.toString(arr));} public static void pa(double[] arr){System.out.println(Arrays.toString(arr));} public static void pa(boolean[] arr){System.out.println(Arrays.toString(arr));} public static void p(Object o){System.out.println(o.toString());} public static void d(Object o){if(DEBUG)System.out.println(o.toString());} public static int[] parseInt(String[] arr){ int[] res = new int[arr.length]; for(int i = 0; i < arr.length; i++)res[i] = Integer.parseInt(arr[i]); return res; } public static int parseInt(Object o){return Integer.parseInt(o.toString());}; } class MyHashMap<E> extends HashMap<E, Integer>{ ArrayList<E> keyArray = new ArrayList<E>(); public void add(E key){add(key, 1);} public void add(E key, Integer value){ if(containsKey(key)){ value += get(key); }else{ keyArray.add(key); } put(key, value); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 11, 1, 41, 13, 17, 2, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [...
[ "import java.util.Scanner;\n\tclass Main{\n\n\t\tpublic static void main(String[] args){\n\tScanner sc=new Scanner(System.in);\n\tint MOUNTAIN[]=new int[10];\n\tfor(int i=0;i<10;i++){\n\t\tMOUNTAIN[i]=sc.nextInt();\n\t}\n\tfor(int i=1;i<10;i++){\n\t\tfor(int j=0;j<10-i;j++){\n\t\t\tif(MOUNTAIN[j]>MOUNTAIN[j+1]){\n\...
import java.util.Scanner; class Main{ public static void main(String[] args){ Scanner sc=new Scanner(System.in); int MOUNTAIN[]=new int[10]; for(int i=0;i<10;i++){ MOUNTAIN[i]=sc.nextInt(); } for(int i=1;i<10;i++){ for(int j=0;j<10-i;j++){ if(MOUNTAIN[j]>MOUNTAIN[j+1]){ int taihi; taihi = MOUNTAIN[j]; MOUNTAIN[j]=MOUNTAIN[j+1]; MOUNTAIN[j+1]=taihi; } } } for(int i=9;i!=6;i--){ System.out.println(MOUNTAIN[i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [...
[ "import java.io.*;\n\nclass Main {\n public static void main(String[] args) throws java.io.IOException{\n int fst = 0,snd = 0,thi = 0;\n int temp;\n BufferedReader in = new BufferedReader(new InputStreamReader(System.in));\n for (int i=0; i<10; i++) {\n int j = Integer.pars...
import java.io.*; class Main { public static void main(String[] args) throws java.io.IOException{ int fst = 0,snd = 0,thi = 0; int temp; BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); for (int i=0; i<10; i++) { int j = Integer.parseInt(in.readLine()); if (j > fst) { temp = snd; snd = fst; thi = temp; fst = j; } else if (j > snd) { thi = snd; snd = j; } else if (j > thi) { thi = j; } } System.out.println(fst); System.out.println(snd); System.out.println(thi); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 2, 18, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 129, 11 ], [ 129, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\n\n\n\npublic class Main {\n\tpublic static void main(String[] args) throws IOException{\n\t BufferedReader br= new BufferedReader(new InputStreamReader(System.in));\n\t int [] mountainsheight= new int[10];\n ...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException{ BufferedReader br= new BufferedReader(new InputStreamReader(System.in)); int [] mountainsheight= new int[10]; for (int i = 0; i < 10; i++) { mountainsheight[i]=Integer.parseInt(br.readLine()); } for (int i = 0; i < mountainsheight.length-1; i++) { for (int j = i + 1; j < mountainsheight.length; j++) { if (mountainsheight[i] < mountainsheight[j]) { int temporary = mountainsheight[i]; mountainsheight[i] = mountainsheight[j]; mountainsheight[j] = temporary; } } } for (int i = 0; i < 3; i++) { System.out.println(mountainsheight[i]); } } }
[ 7, 15, 13, 17, 6, 13, 41, 13, 20, 41, 13, 12, 13, 30, 4, 13, 4, 13, 23, 13, 12, 13, 30, 0, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 12, 13, 30, 4, 18, 13, 13, 4, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 79, 5 ], [ 79, 6 ], [ 6, 7 ], [ 6, 8 ], [ 79, 9 ], [ 9, 10 ], [ 79, 11 ], [ 11, 12 ], [ 11, 13 ], [ 13, 14 ]...
[ "import java.util.*;\n\npublic class Main {\n static Scanner sc = new Scanner(System.in);\n static int[] array;\n public static void main(String[] args) {\n read();\n solve();\n }\n\n static void read(){\n array = new int[10];\n for(int i = 0; i < 10; i++){\n ar...
import java.util.*; public class Main { static Scanner sc = new Scanner(System.in); static int[] array; public static void main(String[] args) { read(); solve(); } static void read(){ array = new int[10]; for(int i = 0; i < 10; i++){ array[i] = sc.nextInt(); } } static void solve(){ Arrays.sort(array); System.out.println(array[9]); System.out.println(array[8]); System.out.println(array[7]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 14, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\nimport java.util.Collections;\n\npublic class Main {\n\tpublic static void main(String[] args) throws IOException{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; import java.util.Collections; public class Main { public static void main(String[] args) throws IOException{ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); Integer[] a =new Integer[10]; //????????????????????? for(int i = 0; i < a.length; i++){ a[i] = Integer.parseInt(br.readLine()); if(a[i] < 0 || a[i] >10000){ i--; } } Arrays.sort(a,Collections.reverseOrder()); for(int i = 0; i < 3; i++){ System.out.println(a[i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 13 ], [ 13, 14 ], [ 13, 15 ], [...
[ "import java.util.*;\n class Main {\n\tpublic static void main(String[] args){\n\t\tint a[]=new int[10];\n\t\tScanner x=new Scanner(System.in);\n\t\tfor(int i=0;i<10;i++){\n\t\t\ta[i]=x.nextInt();\n\t\t}\n\t\tArrays.sort(a);\n\t\tx.close();\n\t\tfor(int j=9;j>=7;j--)\n\t\t\tSystem.out.println(a[j]);\n\t}\n\t\n\n}",...
import java.util.*; class Main { public static void main(String[] args){ int a[]=new int[10]; Scanner x=new Scanner(System.in); for(int i=0;i<10;i++){ a[i]=x.nextInt(); } Arrays.sort(a); x.close(); for(int j=9;j>=7;j--) System.out.println(a[j]); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 13, 13, 17, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 166, 5 ], [ 166, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args)\n\t{\n\t\tScanner sc = new Scanner(System.in);\n\t\tint[] list = new int[10];\n\t\tfor(int i = 0; i < 10; ++i)\n\t\t\tlist[i] = Integer.parseInt(sc.nextLine());\n\t\tQuickSort(list, 0, 10);\n\t\tfor(int i = 9; i > 6; --i)\...
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int[] list = new int[10]; for(int i = 0; i < 10; ++i) list[i] = Integer.parseInt(sc.nextLine()); QuickSort(list, 0, 10); for(int i = 9; i > 6; --i) System.out.println(list[i]); } public static void QuickSort(int[] array, int first, int n) { if(n<=1) return; int Pivot = array[first + n/2 - 1]; int Left = first; int Right = first + n - 1; while(Left <= Right) { while(array[Left] < Pivot) Left++; while(array[Right] > Pivot) Right--; if(Left <= Right) { int tmp = array[Left]; array[Left] = array[Right]; array[Right] = tmp; Left++; Right--; } } QuickSort(array, first, Right - first + 1); QuickSort(array, Left, first + n - Left ); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 2, 18, 13, 13, 17, 2, 13, 2, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 75, 8 ], [ 75, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "\nimport java.util.Arrays;\nimport java.util.Scanner;\n\npublic class Main{\n\tpublic static void main(String[] args){\n\t\tScanner stdIn = new Scanner(System.in);\n\t\tint[] data = new int[10];\n\t\tfor(int i=0;i<10;i++){\n\t\t\tdata[i] = stdIn.nextInt();\n\t\t}\n\t\t\n\t\tArrays.sort(data);\n\t\t\n\t\tfor(int i=...
import java.util.Arrays; import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner stdIn = new Scanner(System.in); int[] data = new int[10]; for(int i=0;i<10;i++){ data[i] = stdIn.nextInt(); } Arrays.sort(data); for(int i=data.length-1;i>=data.length-3;i--){ System.out.println(data[i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 41, 13, 18, 13, 17, 41, 13, 18, 13, 17, 41, 13, 18, 13, 17, 14, 2, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 170, 5 ], [ 170, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\npublic class Main {\n\tpublic static void main(String[] args) throws java.io.IOException {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint M[] = new int[10];\n\t\tfor(int a = 0;a<10;a++){\n\t\t\tM[a] = scan.nextInt();\n\t\t}\n\t\tint No1 = M[0];\n\t\tint No2 = M[1];\n\t\tint No3 = M...
import java.util.Scanner; public class Main { public static void main(String[] args) throws java.io.IOException { Scanner scan = new Scanner(System.in); int M[] = new int[10]; for(int a = 0;a<10;a++){ M[a] = scan.nextInt(); } int No1 = M[0]; int No2 = M[1]; int No3 = M[2]; if(No1 < No2){ No1 = M[1]; No2 = M[0]; } if(No1 < No3){ No3 = No2; No2 = No1; No1 = M[2]; }else if(No2 < No3){ No3 = No2; No2 = M[2]; } for(int b = 3;b<10;b++){ if(No1 < M[b]){ No3 = No2; No2 = No1; No1 = M[b]; }else if(No2 < M[b]){ No3 = No2; No2 = M[b]; }else if(No3 < M[b]){ No3 = M[b]; } } System.out.println(No1 + "\n" + No2 + "\n" + No3); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 41, 13, 17, 42, 17, 30, 41, 13, 4, 18, 13, 0, 18, 13, 40, 13, 4, 18, 13, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.lang.Exception;\nimport java.lang.Integer;\nimport java.lang.String;\nimport java.lang.System;\nimport java.util.Arrays;\n\nclass Main {\n public static void main(String[] a) throws Exception {\n BufferedReader r = new Buffere...
import java.io.BufferedReader; import java.io.InputStreamReader; import java.lang.Exception; import java.lang.Integer; import java.lang.String; import java.lang.System; import java.util.Arrays; class Main { public static void main(String[] a) throws Exception { BufferedReader r = new BufferedReader(new InputStreamReader(System.in)); int [] mountains = new int[10]; int i = 0; while (true) { String s = r.readLine(); mountains[i++] = Integer.valueOf(s); if(i >= 10) break; } Arrays.sort(mountains); for(i = 9; i > 6; i--) { System.out.println(mountains[i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 29, 13, 23, 13, 23, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 17, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 6, 11 ], [ 11, 12 ], [ 6, 13 ], [ 13, 14 ], [...
[ "import java.util.*;\n\nclass Main\n{\n public static int swap(int a, int b)\n {\n return a;\n }\n public static void main(String[] args)\n {\n Scanner input = new Scanner(System.in);\n int a[] = new int[4];\n for (int t = 0; t < 10; t++)\n {\n a[3] = inp...
import java.util.*; class Main { public static int swap(int a, int b) { return a; } public static void main(String[] args) { Scanner input = new Scanner(System.in); int a[] = new int[4]; for (int t = 0; t < 10; t++) { a[3] = input.nextInt(); for (int i = 2; i >= 0; i--) { if (a[i] < a[i+1]) { a[i+1] = swap(a[i], a[i]=a[i+1]); } } } for (int i = 0; i < 3; i++) { System.out.println(a[i]); } input.close(); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.*;\nimport java.io.*;\n\nclass Main{\n\tpublic static void main(String[]args){\n Scanner sc = new Scanner(System.in);\n \tint high[]=new int[10];\n for(int i=0; i<10; i++){\n \t high[i]=sc.nextInt();\t\n \t}\n\tArrays.sort(high);\n\tfor(int i=9; i>6; i-- ) System.out.println...
import java.util.*; import java.io.*; class Main{ public static void main(String[]args){ Scanner sc = new Scanner(System.in); int high[]=new int[10]; for(int i=0; i<10; i++){ high[i]=sc.nextInt(); } Arrays.sort(high); for(int i=9; i>6; i-- ) System.out.println(high[i]); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [...
[ "import java.util.Scanner;\n\nclass Main {\n\n\tpublic static void main(String[] a) {\n\t\t// 入力\n\t\tScanner sc = new Scanner(System.in);\n\t\tint result[] = new int[10];\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\tresult[i] = sc.nextInt();\n\t\t}\n\t\tsc.close();\n\n\t\t// 出力\n\t\tfor (int i = 0; i < 3; i++) {\n\t...
import java.util.Scanner; class Main { public static void main(String[] a) { // 入力 Scanner sc = new Scanner(System.in); int result[] = new int[10]; for (int i = 0; i < 10; i++) { result[i] = sc.nextInt(); } sc.close(); // 出力 for (int i = 0; i < 3; i++) { int maxIndex = i; for (int j = i + 1; j < result.length; j++) { if (result[maxIndex] < result[j]) { maxIndex = j; } } System.out.println(result[maxIndex]); result[maxIndex] = 0;/* if (i < 2) { System.out.println(); }*/ } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 41, 13, 20, 11, 1, 0, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 13, 4, 18, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 131, 11 ], [ 131, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\n\npublic class Main {\n\n\tpublic static void main(String[] args) throws IOException {\n\t\t//?????°?¨????\n int[] Mountain = new int[10];\n int i = 0;\n int first = 0, second = 0, third = 0;\n\t\tS...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { //?????°?¨???? int[] Mountain = new int[10]; int i = 0; int first = 0, second = 0, third = 0; String line; //??????????????????????????? BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); for (i = 0; i < 10; i++) { line = br.readLine(); Mountain[i] = Integer.parseInt(line); //???????????? if (Mountain[i] > first) { third = second; second = first; first = Mountain[i]; continue; } else if (Mountain[i] > second) { third = second; second = Mountain[i]; continue; } else if (Mountain[i] > third) { third = Mountain[i]; continue; } } System.out.println(first); System.out.println(second); System.out.println(third); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 17, 41, 13, 17, 42, 2, 13, 17, 30, 41, 13, 4, 13, 4, 18, 13, 14, 2, 2, 17, 13, 2, 13, 17, 30, 4, 18, 13, 13, 40, 13, 4...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 80, 11 ], [ 80, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.*;\nimport java.io.*;\nimport static java.lang.Integer.parseInt;\n\npublic class Main {\n \n public static void main(String[] arg) throws IOException{\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n ArrayList<Integer> al = new ArrayList<>();\n ...
import java.util.*; import java.io.*; import static java.lang.Integer.parseInt; public class Main { public static void main(String[] arg) throws IOException{ BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); ArrayList<Integer> al = new ArrayList<>(); int i = 0,j=0; while(i<10){ int x = parseInt(br.readLine()); if(0<=x&&x<=10000){ al.add(x); } i++; } Collections.sort(al,Comparator.reverseOrder()); while(j<3){ System.out.println(al.get(j)); j++; } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 41, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 140, 5 ], [ 140, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\n\npublic class Main \n{\n\tpublic static void main(String[] args)\n\t{\n\t\tScanner scan = new Scanner(System.in);\n\t\tint[] heights = new int[10];\n\t\tint temp;\n\t\t\n\t\tfor(int i = 0; i < 10; i++)\n\t\t{\n\t\t\theights[i] = Integer.parseInt(scan.nextLine());\n\t\t}\n\t\t\n\t\tfor(i...
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int[] heights = new int[10]; int temp; for(int i = 0; i < 10; i++) { heights[i] = Integer.parseInt(scan.nextLine()); } for(int i = 0; i < heights.length; i++) { for(int k = 1; k < heights.length - i; k++) { if( heights[k-1] > heights[k]) { temp = heights[k]; heights[k] = heights[k-1]; heights[k-1] = temp; } } } for(int i = heights.length - 1; i > heights.length - 4; i--) { System.out.println(heights[i]); } scan.close(); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 12, 13, 30, 0, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 71, 8 ], [ 71, 9 ], [ 9, 10 ], [ 71, 11 ], [ 11, 12 ], [ 11, 13 ], [ 13, 14 ],...
[ "import java.util.*;\nimport java.util.Arrays;\npublic class Main {\n\n\tprivate static Scanner sc;\n\n\tpublic static void main(String[] args) {\n\t\tsc = new Scanner(System.in);\n\t\tint []a=new int [10];\n\t\tfor(int i=0;i<a.length;i++){\n\t\t\ta[i]=sc.nextInt();\n\t\t}\n\t\tArrays.sort(a);\n\t\tfor(int i=9;i>6;...
import java.util.*; import java.util.Arrays; public class Main { private static Scanner sc; public static void main(String[] args) { sc = new Scanner(System.in); int []a=new int [10]; for(int i=0;i<a.length;i++){ a[i]=sc.nextInt(); } Arrays.sort(a); for(int i=9;i>6;i--){ System.out.println(a[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 13, 4, 18, 18, 13, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 80, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\nimport java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args){\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\tArrayList<Integer> list = new ArrayList<>();\n\t\tfor(int i=0 ; i<10 ;i++){\n\t\t\tint...
import java.util.ArrayList; import java.util.Collections; import java.util.List; import java.util.Scanner; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); ArrayList<Integer> list = new ArrayList<>(); for(int i=0 ; i<10 ;i++){ int a = sc.nextInt(); list.add(a); } Collections.sort(list); System.out.println(list.get(9)); System.out.println(list.get(8)); System.out.println(list.get(7)); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 4, 18, 18, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 62, 5 ], [ 62, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.*;\n\npublic class Main {\n public static void main(String[] args) throws Exception {\n // Here your code !\n Scanner scan = new Scanner(System.in);\n \n int[] m = new int[10];\n for (int i =0 ; i<10 ;i++)\n m[i] = scan.nextInt();\n \n Arrays.sort(m);\n fo...
import java.util.*; public class Main { public static void main(String[] args) throws Exception { // Here your code ! Scanner scan = new Scanner(System.in); int[] m = new int[10]; for (int i =0 ; i<10 ;i++) m[i] = scan.nextInt(); Arrays.sort(m); for( int i=9;i>=7;i--) System.out.println(m[i]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 69, 11 ], [ 69, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tArrayList<Integer> height = new ArrayList<Integer>();\n\t\tScanner sc = new java.util.Scanner(System.in);\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\theight...
import java.util.ArrayList; import java.util.Collections; import java.util.Scanner; public class Main { public static void main(String[] args) { ArrayList<Integer> height = new ArrayList<Integer>(); Scanner sc = new java.util.Scanner(System.in); for (int i = 0; i < 10; i++) { height.add(sc.nextInt()); } Collections.sort(height); for (int i = 9; i > 6; i--) { System.out.println(height.get(i)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 20, 12, 13, 30, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 13, 4, 18, 13, 13, 4, 18, 18, 13, 13, 4, 18, 13, 17, 4, 18, 18,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 93, 11 ], [ 93, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.Scanner;\n\npublic class Main {\n\n\tpublic static Scanner scanner = new Scanner(System.in);\n\n\tpublic static void main(String[] args) {\n\n\t\tArrayList<Integer> hight = new ArrayList<Integer>();\n\n\t\tfor (int i = 0; i < 10; i++) {\n...
import java.util.ArrayList; import java.util.Collections; import java.util.Scanner; public class Main { public static Scanner scanner = new Scanner(System.in); public static void main(String[] args) { ArrayList<Integer> hight = new ArrayList<Integer>(); for (int i = 0; i < 10; i++) { hight.add(input()); } Collections.sort(hight); System.out.println(hight.get(9)); System.out.println(hight.get(8)); System.out.println(hight.get(7)); close(); } public static int input() { return scanner.nextInt(); } public static void close() { if (scanner != null) { scanner.close(); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 20, 41, 13, 38, 5, 13, 30, 4, 18, 18, 13, 13, 17, 30, 42, 2, 0, 13, 4, 18, 13, 17, 30, 41, 13, 4, 18, 13, 13, 14, 2, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 107, 8 ], [ 107, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ]...
[ "import java.io.BufferedReader;\nimport java.io.InputStreamReader;\n\n\npublic class Main {\n\t\n\tpublic static void main(String input[]){\n\t\tint a = 0, b = 0, c=0;\n\t\tBufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in));\n\t\tString fileline;\n\t\ttry{\n\t\t\twhile ((fileline = buffR...
import java.io.BufferedReader; import java.io.InputStreamReader; public class Main { public static void main(String input[]){ int a = 0, b = 0, c=0; BufferedReader buffRead = new BufferedReader(new InputStreamReader(System.in)); String fileline; try{ while ((fileline = buffRead.readLine()) != null){ int height = Integer.parseInt(fileline); if (height > a){ c = b; b = a; a = height; }else if (height > b){ c = b; b = height; }else if (height > c){ c = height; }else{ } } } catch (Exception e){ System.out.println("Failure"); } System.out.println(a); System.out.println(b); System.out.println(c); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 40, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 146, 5 ], [ 146, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\n\npublic class Main\n{\n\tpublic static void main(String[] args)\n\t{\n\t\tScanner scanner = new Scanner(System.in);\n\t\tint[] m = new int[10];\n\t\tint[] h = new int[3];\n\t\t\n\t\t\n\t\tfor(int i=0; i<3; i++)\n\t\t{\n\t\t\th[i] = -1;\n\t\t}\n\t\t\n\t\tfor(int i=0; i<10; i++)\n\t\t{\n\...
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int[] m = new int[10]; int[] h = new int[3]; for(int i=0; i<3; i++) { h[i] = -1; } for(int i=0; i<10; i++) { m[i] = scanner.nextInt(); if(h[0] < m[i]) { h[0] = m[i]; int r = 0; for(int j=1; j<3; j++) { if(h[j] < h[r]) { int buf = h[r]; h[r] = h[j]; h[j] = buf; r = j; } } } } for(int i=2; i>=0; i--) { System.out.println(h[i]+""); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\nimport java.util.Collections;\nimport java.util.Scanner;\n\nclass Main{\n public static void main(String[] args){\n\tfinal Scanner sc = new Scanner(System.in);\n\tInteger[] ar=new Integer[10];\n\tfor(int i=0;i<10;i++) ar[i]=sc.nextInt();\n\tArrays.sort(ar,Collections.reverseOrder());\n...
import java.util.Arrays; import java.util.Collections; import java.util.Scanner; class Main{ public static void main(String[] args){ final Scanner sc = new Scanner(System.in); Integer[] ar=new Integer[10]; for(int i=0;i<10;i++) ar[i]=sc.nextInt(); Arrays.sort(ar,Collections.reverseOrder()); for(int i=0;i<3;i++) System.out.println(ar[i]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 4, 18, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 17, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 130, 11 ], [ 130, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\n\npublic class Main {\n\tpublic static void main(String[] args) throws IOException {\n\t\tint[] data = new int[10];\n\t\tfinal String BR = System.getProperty(\"line.separator\");\n\t\tint first = 0, second = 0, third = ...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { int[] data = new int[10]; final String BR = System.getProperty("line.separator"); int first = 0, second = 0, third = 0; BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); for (int i = 0; i < 10; i++) { data[i] = Integer.parseInt(in.readLine()); } for (int datum : data) { int temp1 = 0, temp2 = 0; if (first < datum) { temp1 = first; temp2 = second; first = datum; second = temp1; third = temp2; } else if (second < datum) { temp2 = second; second = datum; third = temp2; } else if (third < datum) { third = datum; } } System.out.println(first + BR + second + BR + third); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 13, 4, 18, 13, 13, 11, 1, 41, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 79, 11 ], [ 79, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.Scanner;\n\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\tArrayList<Integer> list = new ArrayList<Integer>();\n\t\t\n\t\tfor(int i = 0; i < 10; i++){\n\t\t\tint tm...
import java.util.ArrayList; import java.util.Collections; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); ArrayList<Integer> list = new ArrayList<Integer>(); for(int i = 0; i < 10; i++){ int tmp = sc.nextInt(); list.add(tmp); } Collections.sort(list); Collections.reverse(list); for(int i = 0; i < 3; i++){ int tmp = list.get(i); System.out.println(tmp); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 42, 4, 18, 13, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 71, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\nimport java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n List<Integer> list = new ArrayList<Integer>();\n Scanner scanner = new Scanner(System.in);\n while (scanner.hasNe...
import java.util.ArrayList; import java.util.Collections; import java.util.List; import java.util.Scanner; public class Main { public static void main(String[] args) { List<Integer> list = new ArrayList<Integer>(); Scanner scanner = new Scanner(System.in); while (scanner.hasNext()) { list.add(Integer.parseInt(scanner.next())); } Collections.sort(list); Collections.reverse(list); for (int i = 0; i < 3; i++) { System.out.println(list.get(i)); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 18, 13, 13, 4, 18, 13, 2, 4, 18, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 86, 11 ], [ 86, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.Scanner;\n\npublic class Main {\n public static void main(String[] args) {\n Scanner input = new Scanner(System.in);\n ArrayList<Integer> out = new ArrayList<Integer>();\n for (int i = 0; i < 10; i++) {\n ...
import java.util.ArrayList; import java.util.Collections; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner input = new Scanner(System.in); ArrayList<Integer> out = new ArrayList<Integer>(); for (int i = 0; i < 10; i++) { out.add(input.nextInt()); } Collections.sort(out); System.out.println(out.get(out.size()-1)); System.out.println(out.get(out.size()-2)); System.out.println(out.get(out.size()-3)); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 17, 38, 5, 13, 30, 4, 18, 18, 13, 13, 13, 30, 14, 2, 13, 17, 30, 38, 5, 13, 30, 30, 4, 18, 13, 30, 0, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 104, 8 ], [ 104, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ]...
[ "import java.util.Arrays;\nimport java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner sc = null;\n\n\t\ttry {\n\t\t\tsc = new Scanner(System.in);\n\t\t\tint[] hillList = new int[10];\n\n\t\t\tfor (int i = 0; i < 10; i++) {\n\t\t\t\thillList[i] = sc.nextInt();\n\t\t\t...
import java.util.Arrays; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = null; try { sc = new Scanner(System.in); int[] hillList = new int[10]; for (int i = 0; i < 10; i++) { hillList[i] = sc.nextInt(); } Arrays.sort(hillList); int n = hillList.length - 1; for (int j = 0; j < 3; j++) { System.out.println(hillList[n]); n--; } }catch (Exception e) { System.out.println(e); } finally { if (sc != null) { try { sc.close(); } catch (Exception e) { // TODO: handle exception } } } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 18, 13, 13, 4, 18, 13, 2, 4, 18, 13, 17, 4, 18, 18, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 80, 5 ], [ 80, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.*;\npublic class Main{\n public static void main(String[] args){\n\tScanner scan = new Scanner(System.in);\n\tList<Integer> list = new ArrayList<Integer>();\n\tfor(int i = 0; i < 10; i++){\n\t list.add(scan.nextInt());\n\t}\n\n\tCollections.sort(list);\n\tSystem.out.println(list.get(list.siz...
import java.util.*; public class Main{ public static void main(String[] args){ Scanner scan = new Scanner(System.in); List<Integer> list = new ArrayList<Integer>(); for(int i = 0; i < 10; i++){ list.add(scan.nextInt()); } Collections.sort(list); System.out.println(list.get(list.size()-1)); System.out.println(list.get(list.size()-2)); System.out.println(list.get(list.size()-3)); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 18, 13, 13, 17, 18, 13, 17, 18, 13, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 61, 8 ], [ 61, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.*;\nimport java.util.*;\npublic class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n int[] h = new int[10];\n for(int i = 0; i < 10; i++){\n h[i] = sc.nextInt();\n }\n Arrays.sort(h);\n System.out.pri...
import java.io.*; import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int[] h = new int[10]; for(int i = 0; i < 10; i++){ h[i] = sc.nextInt(); } Arrays.sort(h); System.out.printf("%d\n%d\n%d\n", h[9], h[8], h[7]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 41, 13, 20, 17, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 13, 4, 18, 13, 0, 18, 13, 13, 13, 0, 18, 13, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 145, 11 ], [ 145, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\n\npublic class Main {\n\n\tpublic static void main(String[] args) throws IOException {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tString str;\n\t\tString[] heightstr = new String...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String str; String[] heightstr = new String[10]; int[] heightint = new int[10]; for (int i = 0; i <= 9; i++) { str = br.readLine(); heightstr[i] = str; heightint[i] = Integer.parseInt(heightstr[i]); } for (int j = 0; j <= 8; j++) { for (int k = j + 1; k <= 9; k++) { Boolean isBig = heightint[j] < heightint[k]; if (isBig) { int temporary = heightint[j]; heightint[j] = heightint[k]; heightint[k] = temporary; } } } System.out.println(heightint[0]); System.out.println(heightint[1]); System.out.println(heightint[2]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 39, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 82, 11 ], [ 82, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\nimport java.util.Comparator;\nimport java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String args[] ) throws Exception {\n Scanner sc = new Scanner(System.in);\n Integer array[] = {1, 1, 1, 1, 1,1, 1, 1, 1, 1}; \n for(int i = 0; i < 10; ++i){\n ...
import java.util.Arrays; import java.util.Comparator; import java.util.Scanner; public class Main { public static void main(String args[] ) throws Exception { Scanner sc = new Scanner(System.in); Integer array[] = {1, 1, 1, 1, 1,1, 1, 1, 1, 1}; for(int i = 0; i < 10; ++i){ array[i] = sc.nextInt(); } Arrays.sort(array, Comparator.reverseOrder()); for(int i = 0; i < 3; ++i){ System.out.println(array[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 42, 4, 18, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 4, 18, 18, 13, 13, 4, 18, 13, 2, 2, 4, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 62, 8 ], [ 62, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.*;\nimport java.lang.*;\npublic class Main {\n public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n List<Integer> list = new ArrayList<Integer>();\n while (sc.hasNext()) list.add(sc.nextInt());\n Collections.sort(list);\n for (int ...
import java.util.*; import java.lang.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); List<Integer> list = new ArrayList<Integer>(); while (sc.hasNext()) list.add(sc.nextInt()); Collections.sort(list); for (int i = 0; i < 3; i++) System.out.println(list.get(list.size() - i - 1)); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 42, 2, 2, 0, 13, 4, 18, 13, 17, 2, 4, 18, 13, 17, 30, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Collections;\nimport java.util.PriorityQueue;\n\n\n\npublic class Main {\n\n\tpublic static void main(String[] args) throws IOException {\n\t\tPriorityQueue<Integer> pq = new PriorityQueue<Integer>(3, C...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Collections; import java.util.PriorityQueue; public class Main { public static void main(String[] args) throws IOException { PriorityQueue<Integer> pq = new PriorityQueue<Integer>(3, Collections.reverseOrder()); BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); String s; while ((s = in.readLine()) != null && s.length() != 0) { pq.add(Integer.parseInt(s)); // System.out.println(s); // An empty line or Ctrl-Z terminates the program } for (int i = 0; i < 3; i++) { System.out.println(pq.poll()); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 0, 18, 13, 13, 13, 4, 18, 13, 13, 4, 18, 18, 13, 13, 18, 13, 17, 4...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 73, 8 ], [ 73, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\nimport java.util.Scanner;\npublic class Main {\n public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n int[] arr = new int[10];\n for (int i =0; i< 10; i++){\n int a = scan.nextInt();\n arr[i] = a;\n }\n ...
import java.util.Arrays; import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int[] arr = new int[10]; for (int i =0; i< 10; i++){ int a = scan.nextInt(); arr[i] = a; } Arrays.sort(arr); System.out.println(arr[9]); System.out.println(arr[8]); System.out.println(arr[7]); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 17, 41, 13, 17, 41, 13, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 14, 2, 13, 13, 30, 0, 13, 13, 0, 13, 13, 0, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 95, 8 ], [ 95, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.*;\nimport java.io.*;\n\npublic class Main {\n public static void main(String[] args) throws IOException {\n Scanner sc=new Scanner(System.in);\n int max1=0,max2=0,max3=0;\n for (int i=1;i<=10;i++){\n int h=sc.nextInt();\n if (h>max1){\n ...
import java.util.*; import java.io.*; public class Main { public static void main(String[] args) throws IOException { Scanner sc=new Scanner(System.in); int max1=0,max2=0,max3=0; for (int i=1;i<=10;i++){ int h=sc.nextInt(); if (h>max1){ max3=max2; max2=max1; max1=h; } else if (h>max2){ max3=max2; max2=h; } else if (h>max3) max3=h; } System.out.println(max1); System.out.println(max2); System.out.println(max3); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 41, 13, 20, 11, 1, 0, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 0, 13, 17, 2, 13, 17, 1, 40, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Scanner;\nimport java.util.Arrays;\n \nclass Main\n{\n\tpublic static void main (String[] args) throws java.lang.Exception\n\t{\n\t\tint a[] = new int[10];\n\t\tint i;\n \n\t\tScanner cin = new Scanner(System.in);\n\t\tfor (i = 0; i < 10; i++){\n\t\t\ta[i] = cin.nextInt();\n\t\t}\n \n\t\tArrays.so...
import java.util.Scanner; import java.util.Arrays; class Main { public static void main (String[] args) throws java.lang.Exception { int a[] = new int[10]; int i; Scanner cin = new Scanner(System.in); for (i = 0; i < 10; i++){ a[i] = cin.nextInt(); } Arrays.sort(a); for (i = 9; i > 6; i--){ System.out.println(a[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "/* Name of the class has to be \"Main\" only if the class is public. */\nimport java.util.Scanner;\nimport java.util.Arrays;\n\nclass Main\n{\n\tpublic static void main (String[] args) throws java.lang.Exception\n\t{\n\t\tint [] x = new int[10];\n\t\t\n\t\tScanner cin = new Scanner(System.in);\n\t\tfor (int i = 0;...
/* Name of the class has to be "Main" only if the class is public. */ import java.util.Scanner; import java.util.Arrays; class Main { public static void main (String[] args) throws java.lang.Exception { int [] x = new int[10]; Scanner cin = new Scanner(System.in); for (int i = 0; i < 10; i++) { x[i] = cin.nextInt(); } Arrays.sort(x); for (int i = 9; i >= 7; i--) { System.out.println(String.valueOf(x[i])); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.*;import java.util.*;class Main{public static void main(String[] args) throws IOException{BufferedReader br=new BufferedReader(new InputStreamReader(System.in));int[] k=new int[10];for(int i=0;i<10;i++)k[i]=Integer.parseInt(br.readLine());Arrays.sort(k);for(int i=0;i<3;i++)System.out.println(k[9-i])...
import java.io.*;import java.util.*;class Main{public static void main(String[] args) throws IOException{BufferedReader br=new BufferedReader(new InputStreamReader(System.in));int[] k=new int[10];for(int i=0;i<10;i++)k[i]=Integer.parseInt(br.readLine());Arrays.sort(k);for(int i=0;i<3;i++)System.out.println(k[9-i]);}}
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 18, 13, 13, 41...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 128, 5 ], [ 128, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ],...
[ "import java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\tScanner scan = new Scanner(System.in);\n\t\tint[] data = new int[10];\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\tdata[i] = scan.nextInt();\n\t\t}\n\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\tint a = data[i];\n\t\t\t...
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); int[] data = new int[10]; for (int i = 0; i < 10; i++) { data[i] = scan.nextInt(); } for (int i = 0; i < 10; i++) { int a = data[i]; int indexMin = i; for (int k = i + 1; k < 10; k++) { if (data[k] < a) { a = data[k]; indexMin = k; } } int temp = data[i]; data[i] = data[indexMin]; data[indexMin] = temp; } for (int i = 9; i >= 7; i--) { System.out.println(data[i]); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 18, 13, 13, 18, 13, 17, 4, 18, 18, 13, 13, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 12 ], [ 12, 13 ], [ 12, 14 ], [...
[ "import java.util.*;\n\nclass Main {\n\tpublic static void main(String[] args) {\n\t\tScanner scanner = new Scanner(System.in);\n\t\tint[] height = new int[10];\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\theight[i] = scanner.nextInt();\n\t\t}\n\t\tArrays.sort(height);\n\t\tSystem.out.println(height[9]);\n\t\tSystem....
import java.util.*; class Main { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int[] height = new int[10]; for (int i = 0; i < 10; i++) { height[i] = scanner.nextInt(); } Arrays.sort(height); System.out.println(height[9]); System.out.println(height[8]); System.out.println(height[7]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\n\nclass Main{\n public static void main(String[] a) throws IOException{\n \tBufferedReader in = new BufferedReader(new InputStreamReader(System.in));\n \tint mountains[] = new int[10];\n ...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; class Main{ public static void main(String[] a) throws IOException{ BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); int mountains[] = new int[10]; for(int i=0;i<10;i++){ mountains[i] = Integer.parseInt(in.readLine()); } Arrays.sort(mountains); for(int i = mountains.length-1;i > mountains.length-4;i--){ System.out.println(mountains[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 42, 40, 2, 2, 17, 13, 2, 13, 17, 30, 0, 13, 4, 18, 13,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 94, 11 ], [ 94, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\nimport java.util.Comparator;\nimport java.util.Scanner;\n\npublic class Main{\n public static void main(String[] a){\n \tScanner scanner = new Scanner(System.in);\n \tInteger[] data = new Integer[10];\n \tfor (int i = 0; i < 10; i++) {\n \t\tint number = scanner.nextInt();\...
import java.util.Arrays; import java.util.Comparator; import java.util.Scanner; public class Main{ public static void main(String[] a){ Scanner scanner = new Scanner(System.in); Integer[] data = new Integer[10]; for (int i = 0; i < 10; i++) { int number = scanner.nextInt(); while (!(0 <= number && number <= 10000)) { number = scanner.nextInt(); } data[i] = number; } scanner.close(); Arrays.sort(data, Comparator.reverseOrder()); for (int i = 0; i < 3; i++) { System.out.println(data[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 0, 18, 13, 13, 4, 18, 13, 13, 4, 18, 13, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 82, 14 ], ...
[ "// Created by bisuk on 2014/09/18.\n//\n\nimport java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.util.Collections;\nimport java.util.Arrays;\n\npublic class Main {\n\tpublic static void main(String[] args) throws java.io.IOException {\n\t\t//int[] ls = new int[10];\n\t\tInteger[] ls = new I...
// Created by bisuk on 2014/09/18. // import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Collections; import java.util.Arrays; public class Main { public static void main(String[] args) throws java.io.IOException { //int[] ls = new int[10]; Integer[] ls = new Integer[10]; BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); for (int i = 0; i < 10; i++) { String s = in.readLine(); ls[i] = Integer.valueOf(s); } //System.out.println("ls: " + Arrays.toString(ls)); //Arrays.sort(ls); Arrays.sort(ls, Collections.reverseOrder()); //System.out.println("ls: " + Arrays.toString(ls)); //for(int h : ls){ for (int i = 0; i < 3; i++) { System.out.println(ls[i]); } } } /* > javac xxx.java > java xxx */
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 41, 13, 12, 13, 30, 0, 13, 20, 41, 13, 20, 41, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 13, 4, 18, 13, 14, 2, 13, 17, 30, 4, 18, 13, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 89, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\nimport java.util.Scanner;\n\npublic class Main {\n private static Scanner scan;\n\n public static void main(String[] args) {\n scan = new Scanner(System.in);\n List<Integer> list = new ArrayList<Integer>();\n ...
import java.util.ArrayList; import java.util.Collections; import java.util.List; import java.util.Scanner; public class Main { private static Scanner scan; public static void main(String[] args) { scan = new Scanner(System.in); List<Integer> list = new ArrayList<Integer>(); int value; for (int i = 0; i < 10; i++) { value = scan.nextInt(); if (value <= 10000) { list.add(value); } } Collections.sort(list); System.out.println(list.get(9)); System.out.println(list.get(8)); System.out.println(list.get(7)); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 38, 5, 13, 30, 30, 42, 4, 18, 13, 30, 4, 18, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import static java.util.Comparator.reverseOrder;\n\nimport java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tBufferedReader br = new BufferedReader(ne...
import static java.util.Comparator.reverseOrder; import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; import java.util.List; public class Main { public static void main(String[] args) { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); List<Integer> hillsHightList = new ArrayList<>(); try { while (br.ready()) { hillsHightList.add(Integer.valueOf(br.readLine())); } } catch (Exception e) { // TODO: handle exception } Collections.sort(hillsHightList, reverseOrder()); System.out.println(hillsHightList.get(0)); System.out.println(hillsHightList.get(1)); System.out.println(hillsHightList.get(2)); System.exit(0); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 38, 5, 13, 30, 4, 18, 13, 5, 13, 30, 4, 18, 13, 30, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 92, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\n\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tBufferedReader in = new BufferedReader(new InputStreamReader(System.in));\n\n\t\tint[] data = new int[10];\n\t\ttry {\n\t\...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.Arrays; public class Main { public static void main(String[] args) { BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); int[] data = new int[10]; try { for (int i = 0; i < 10; i++) { data[i] = Integer.parseInt(in.readLine()); } Arrays.sort(data); for (int i = 0; i < 3; i++) { System.out.println(data[9 - i]); } } catch (NumberFormatException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 70, 8 ], [ 70, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\nimport java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] args){\n\t\tScanner std = new Scanner(System.in);\n\t\tint array[] = new int[10];\n\t\tfor(int i=0; i<10; i++){\n\t\t\tarray[i] = Integer.parseInt(std.next());\n\t\t}\n\t\tArrays.sort(array);\n\t\tfor(int...
import java.util.Arrays; import java.util.Scanner; public class Main { public static void main(String[] args){ Scanner std = new Scanner(System.in); int array[] = new int[10]; for(int i=0; i<10; i++){ array[i] = Integer.parseInt(std.next()); } Arrays.sort(array); for(int i=9; i>6; i--){ System.out.println(array[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 38, 5, 13, 30, 30, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\n\nclass Main {\n\tpublic static void main(String[] a) {\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\n\t\tint[] mt = new int[10];\n\t\ttry {\n\t\t\tfor (int i = 0; i < mt.length; i++) {\...
import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; class Main { public static void main(String[] a) { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int[] mt = new int[10]; try { for (int i = 0; i < mt.length; i++) { mt[i] = Integer.parseInt(br.readLine()); } } catch (Exception e) { } Arrays.sort(mt); System.out.println(mt[9]); System.out.println(mt[8]); System.out.println(mt[7]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 38, 5, 13, 30, 4, 18, 18, 13, 13, 17, 30, 41, 13, 20, 17, 41, 13, 39, 17, 17, 17, 41, 13, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.InputStreamReader;\nimport java.util.Arrays;\nclass Main{\n public static void main(String args[]){\n\ttry{\n\t int x[] = new int[10];\n\t int a[] = {0,0,0};\n\t int temp;\n\t InputStreamReader is = new InputStreamReader(System.in);\n\t BufferedReade...
import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Arrays; class Main{ public static void main(String args[]){ try{ int x[] = new int[10]; int a[] = {0,0,0}; int temp; InputStreamReader is = new InputStreamReader(System.in); BufferedReader br = new BufferedReader(is); for(int i=0;i<10;i++){ x[i] = Integer.parseInt(br.readLine()); if(a[0] < x[i]){ temp = a[0]; a[0] = x[i]; x[i] = temp; } if(a[1] < x[i]){ temp = a[1]; a[1] = x[i]; x[i] = temp; } if(a[2] < x[i]){ temp = a[2]; a[2] = x[i]; x[i] = temp; } } System.out.println(a[0]); System.out.println(a[1]); System.out.println(a[2]); } catch(Exception e){ System.out.printf("error"); } } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 0, 13, 20, 17, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 11, 1, 41, 13, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 127, 5 ], [ 127, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 8, 11 ], [ 11, 12 ], [ 11, 13 ], [ 8, 15 ],...
[ "import java.util.Scanner;\npublic class Main {\n\tpublic static void main(String[] args) {\n\t\tint[] Num;\n\t\tNum = new int[11];\n\t\tScanner n=new Scanner(System.in);\n\t\t\tfor (int i = 0; i < 10;i++){\n\t\t\t\tNum[i]=n.nextInt();\n\t\t}\n\t\t\n\t\t\tfor (int a = 9; a >= 0; a--){\n\t\t\t\tfor (int b = 0; b < a...
import java.util.Scanner; public class Main { public static void main(String[] args) { int[] Num; Num = new int[11]; Scanner n=new Scanner(System.in); for (int i = 0; i < 10;i++){ Num[i]=n.nextInt(); } for (int a = 9; a >= 0; a--){ for (int b = 0; b < a; b++){ if (Num[b] < Num[b+1]){ Num[10]=Num[b]; Num[b]=Num[b+1]; Num[b+1]=Num[10]; } } } System.out.println(Num[0]); System.out.println(Num[1]); System.out.println(Num[2]); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 14, 2, 2, 18, 13, 13, 17, 2, 18, 13, 13, 17, 30, 4, 18, 18,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 85, 8 ], [ 85, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\nimport java.util.Scanner;\n\npublic class Main {\n\n\tpublic static void main(String[] args) {\n\t\t@SuppressWarnings(\"resource\")\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint[] mountHill = new int[10];\n\n\t\tfor (int i = 0; i < 10; i++) {\n\t\t\tmountHill[i] = sc.nextInt();\n\n...
import java.util.Arrays; import java.util.Scanner; public class Main { public static void main(String[] args) { @SuppressWarnings("resource") Scanner sc = new Scanner(System.in); int[] mountHill = new int[10]; for (int i = 0; i < 10; i++) { mountHill[i] = sc.nextInt(); if (mountHill[i] > 10000 || mountHill[i] < 0) { System.out.println("error"); } } Arrays.sort(mountHill); System.out.println(mountHill[9] + "\n" + mountHill[8] + "\n" + mountHill[7]); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17, 1,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 74, 11 ], [ 74, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.lang.reflect.Array;\nimport java.util.Arrays;\nimport java.util.Scanner;\n\npublic class Main {\n\n public static void main(String[] args) {\n // TODO 自動生成されたメソッド・スタブ\n Scanner in = new Scanner(System.in);\n int [] hs = new int[10];\n for(int i=0;i<10;i++){\n h...
import java.lang.reflect.Array; import java.util.Arrays; import java.util.Scanner; public class Main { public static void main(String[] args) { // TODO 自動生成されたメソッド・スタブ Scanner in = new Scanner(System.in); int [] hs = new int[10]; for(int i=0;i<10;i++){ hs[i] = in.nextInt(); } Arrays.sort(hs); for(int i=0;i<3;i++){ System.out.println(hs[10-i-1]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 41, 13, 20, 38, 5, 13, 30, 4, 18, 13, 5, 13, 30, 4, 18, 13, 30, 42, 2, 0, 13, 4, 18, 13, 17, 30, 4, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\n\n class Main {\n public static void main(String[] args) {\n BufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n Strin...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; class Main { public static void main(String[] args) { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String str; ArrayList<Integer> al = new ArrayList<Integer>(); try { while((str = br.readLine()) != null) { al.add( Integer.parseInt(str) ); } } catch (NumberFormatException e) { e.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } Collections.sort(al); Collections.reverse(al); for(int i=0; i<3; i++) { System.out.println(al.get(i)); } } }
[ 7, 15, 13, 17, 6, 13, 41, 13, 41, 13, 17, 12, 13, 30, 41, 13, 20, 0, 13, 20, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 11, 1, 41, 13, 17, 2, 13, 13, 1, 40, 13, 30, 30, 41,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 125, 5 ], [ 125, 6 ], [ 6, 7 ], [ 125, 8 ], [ 8, 9 ], [ 8, 10 ], [ 125, 11 ], [ 11, 12 ], [ 11, 13 ], [ 13, 14...
[ "\nimport java.util.Scanner;\n\npublic class Main {\n\t\n\tprivate static int a[];\n\tprivate static int N = 10;\n\t\n\tpublic static void main(String[] args) {\n\t\tScanner sc = new Scanner( System.in );\n\t\t\n\t\ta = new int[N];\n\t\t\n\t\t//入力\n\t\tfor (int i = 0; i < N; i++) {\n\t\t\ta[i] = sc.nextInt();\n\t\t...
import java.util.Scanner; public class Main { private static int a[]; private static int N = 10; public static void main(String[] args) { Scanner sc = new Scanner( System.in ); a = new int[N]; //入力 for (int i = 0; i < N; i++) { a[i] = sc.nextInt(); } //最大値選択法 for (int i = 0; i < N; i++) { int max = i; for (int j = i+1; j < N; j++) { if(a[j] > a[max]) { max = j; } } int t = a[i]; a[i] = a[max]; a[max] = t; } //出力 for (int i = 0; i < 3; i++) { System.out.println(a[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 4, 18, 13, 4, 18, 13, 4, 18, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "\nimport java.io.BufferedReader;\nimport java.io.IOException;\nimport java.io.InputStreamReader;\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.List;\n\npublic class Main {\n\n\tpublic static void main(String[] args) throws IOException {\n\n\t\tList<Integer> hills = new ArrayList<Int...
import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Collections; import java.util.List; public class Main { public static void main(String[] args) throws IOException { List<Integer> hills = new ArrayList<Integer>(); InputStreamReader isr = new InputStreamReader(System.in); BufferedReader br = new BufferedReader(isr); for(int i=0; i<10; ++i){ hills.add(Integer.parseInt(br.readLine())); } Collections.sort(hills); System.out.println(hills.get(9)); System.out.println(hills.get(8)); System.out.println(hills.get(7)); } }
[ 7, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 17, 41, 13, 17, 41, 13, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 42, 2, 13, 17, 30, 41, 13, 17, 42, 2, 13, 13, 30, 1...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 6, 7 ], [ 6, 8 ], [ 8, 9 ], [ 9, 10 ], [ 9, 11 ], [ 8, 13 ], [ 13, 14 ], [ 13, 15 ], [...
[ "import java.util.Scanner;\n\nclass Main {\n\tpublic static void main(String[] args) {\n\n\t\t//??????\n\t\tint tbl[] = new int[10];\n\t\t//\n\t\tint c = 9;\n\t\tint tmp;\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\t\t\n\t\t//????????????????´?\n\t\tfor(int i = 0; i < 10; i++) {\n\t\t\ttbl[i] = sc.nextInt();\...
import java.util.Scanner; class Main { public static void main(String[] args) { //?????? int tbl[] = new int[10]; // int c = 9; int tmp; Scanner sc = new Scanner(System.in); //????????????????´? for(int i = 0; i < 10; i++) { tbl[i] = sc.nextInt(); } //??´???(??????) while(c > 0) { int i = 0; while(i < c) { if(tbl[i] < tbl[i+1]) { tmp = tbl[i]; tbl[i] = tbl[i+1]; tbl[i+1] = tmp; } i++; } c--; } //?????? for(int i = 0; i < 3; i++) { System.out.println(tbl[i]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 4, 18, 13, 4, 18, 13, 13, 4, 18, 13, 13, 4, 18...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "import java.io.IOException;\nimport java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.Scanner;\n\nclass Main{\n\t public static void main(String[] args)throws IOException{\n\t\t Scanner sc = new Scanner(System.in);\n\t\t ArrayList<Integer> al = new ArrayList<Integer>();\n\t\t for(int i = 0; i< ...
import java.io.IOException; import java.util.ArrayList; import java.util.Collections; import java.util.Scanner; class Main{ public static void main(String[] args)throws IOException{ Scanner sc = new Scanner(System.in); ArrayList<Integer> al = new ArrayList<Integer>(); for(int i = 0; i< 10; i++){ int w = sc.nextInt(); al.add(Integer.valueOf(w)); } Collections.sort(al); System.out.println(al.get(9)); System.out.println(al.get(8)); System.out.println(al.get(7)); } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 41, 13, 20, 17, 42, 4, 18, 13, 30, 0, 13, 4, 18, 13, 14, 2, 18, 13, 17, 13, 30, 0, 18, 13, 17, 18, 13, 17, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 10, 11 ], [ 10, 12 ], [ 0, 13 ], [ 13, 14 ], ...
[ "/* package whatever; // don't place package name! */\n \nimport java.util.*;\nimport java.lang.*;\nimport java.io.*;\n \nimport java.util.ArrayList;\nimport java.util.List;\n \n/* Name of the class has to be \"Main\" only if the class is public. */\nclass Main\n{\n public static void main (String[] args) throws...
/* package whatever; // don't place package name! */ import java.util.*; import java.lang.*; import java.io.*; import java.util.ArrayList; import java.util.List; /* Name of the class has to be "Main" only if the class is public. */ class Main { public static void main (String[] args) throws java.lang.Exception { //文字列読込み Scanner sc = new Scanner(System.in); //結果格納 int scInt; int[] check = new int[3]; while (sc.hasNext()) { //1行読込み scInt = sc.nextInt(); if (check[0] < scInt) { check[2] = check[1]; check[1] = check[0]; check[0] = scInt; } else if (check[1] < scInt) { check[2] = check[1]; check[1] = scInt; } else if (check[2] < scInt) { check[2] = scInt; } else { } } System.out.println(check[0]); System.out.println(check[1]); System.out.println(check[2]); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 0, 13, 20, 17, 11, 1, 41, 13, 17, 2, 13, 18, 13, 13, 1, 40, 13, 30, 30, 0, 18, 13, 13, 4, 18, 13, 4, 18, 13, 13, 11, 1, 41, 13, 17, 2, 13, 17,...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.Arrays;\n//List of Top 3 Hills\nimport java.util.Scanner;\n\nclass Main{\n public static void main(String[] a){\n Scanner sc = new Scanner(System.in);\n int hight[];\n hight = new int[10];\n \n// System.out.println(\"hight.length=\"+hight.length);\n for...
import java.util.Arrays; //List of Top 3 Hills import java.util.Scanner; class Main{ public static void main(String[] a){ Scanner sc = new Scanner(System.in); int hight[]; hight = new int[10]; // System.out.println("hight.length="+hight.length); for(int i=0; i<hight.length; i++) { hight[i]=sc.nextInt(); } // System.out.println("in end"); Arrays.sort(hight); for(int i=0; i<3; i++) { System.out.println(hight[(hight.length-1-i)]); } } }
[ 7, 15, 13, 17, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 20, 11, 1, 41, 13, 17, 2, 13, 17, 1, 40, 13, 30, 30, 41, 13, 4, 18, 13, 41, 13, 4, 18, 13, 13, 4, 18, 13, 13, 4, 18, 13, 4, 18, 13...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 0, 10 ], [ 86, 11 ], [ 86, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import java.util.ArrayList;\nimport java.util.Collections;\nimport java.util.Scanner;\n\npublic class Main {\n\tpublic static void main(String[] a) {\n\n\t\t//????????¶?????\\??????????????????\n\t\tScanner scan = new Scanner(System.in);\n\n\t\t// TODO ?????????????????????????????????????????????\n\t\t//?????????...
import java.util.ArrayList; import java.util.Collections; import java.util.Scanner; public class Main { public static void main(String[] a) { //????????¶?????\?????????????????? Scanner scan = new Scanner(System.in); // TODO ????????????????????????????????????????????? //?????????????????? ArrayList<Integer> list = new ArrayList<Integer>(); //????????¶???????????????????????°?????????????????? for(int i =0; i<10; i++){ String stra = scan.next(); int str = Integer.parseInt(stra); list.add(str); } //???????????? scan.close(); //????????? Collections.sort(list); //?????? System.out.println(list.get(9)); System.out.println(list.get(8)); System.out.println(list.get(7)); } }
[ 7, 15, 13, 17, 15, 13, 17, 6, 13, 12, 13, 30, 41, 13, 20, 41, 13, 42, 2, 0, 13, 4, 18, 13, 17, 30, 41, 13, 4, 18, 13, 17, 17, 41, 13, 4, 13, 18, 13, 17, 41, 13, 4, 13, 18, 13, 17, 14, 2, 2, 2, 2, 17, 13, 2, ...
[ [ 0, 1 ], [ 1, 2 ], [ 1, 3 ], [ 0, 4 ], [ 4, 5 ], [ 4, 6 ], [ 0, 7 ], [ 7, 8 ], [ 7, 9 ], [ 9, 10 ], [ 9, 11 ], [ 11, 12 ], [ 12, 13 ], [ 12, 14 ], ...
[ "import static java.lang.Integer.parseInt;\nimport java.io.*;\n\nclass Main{\n public static void main(String[] a) throws IOException{\n\n BufferedReader input = new BufferedReader(new InputStreamReader(System.in));\n String s;\n\n while((s = input.readLine())!=null){\n String[] n...
import static java.lang.Integer.parseInt; import java.io.*; class Main{ public static void main(String[] a) throws IOException{ BufferedReader input = new BufferedReader(new InputStreamReader(System.in)); String s; while((s = input.readLine())!=null){ String[] num = s.split(" ",0); int x = parseInt(num[0]); int y = parseInt(num[1]); if(0 <= x && x <=1000000 && 0 <= y && y <= 1000000){ int z = x + y; System.out.println(Integer.toString(z).length()); } } } }