結果
| 問題 | No.571 3人兄弟(その2) | 
| コンテスト | |
| ユーザー |  fal_rnd | 
| 提出日時 | 2017-10-10 22:51:40 | 
| 言語 | Java (openjdk 23) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 139 ms / 2,000 ms | 
| コード長 | 541 bytes | 
| コンパイル時間 | 2,339 ms | 
| コンパイル使用メモリ | 79,176 KB | 
| 実行使用メモリ | 54,132 KB | 
| 最終ジャッジ日時 | 2024-11-17 08:34:04 | 
| 合計ジャッジ時間 | 4,925 ms | 
| ジャッジサーバーID (参考情報) | judge2 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 2 | 
| other | AC * 12 | 
ソースコード
import java.util.Comparator;
import java.util.Scanner;
import java.util.stream.Stream;
public class Main{
	static Scanner s=new Scanner(System.in);
	static int getInt(){return Integer.parseInt(s.next());}
	public static void main(String[] $){
		int[]h=new int[3];
		int[]w=new int[3];
		h[0]=getInt();
		w[0]=getInt();
		h[1]=getInt();
		w[1]=getInt();
		h[2]=getInt();
		w[2]=getInt();
		Stream.of('A','B','C')
		.sorted(Comparator.<Character>comparingInt(o->-h[o-'A']).thenComparingInt(o->w[o-'A']))
		.forEach(System.out::println);
	}
}
            
            
            
        