結果

問題 No.570 3人兄弟(その1)
ユーザー YOSHIYOSHI
提出日時 2021-03-20 13:38:33
言語 Java21
(openjdk 21)
結果
AC  
実行時間 44 ms / 2,000 ms
コード長 667 bytes
コンパイル時間 3,651 ms
コンパイル使用メモリ 72,776 KB
実行使用メモリ 51,464 KB
最終ジャッジ日時 2023-08-13 05:59:34
合計ジャッジ時間 4,626 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 43 ms
49,544 KB
testcase_01 AC 43 ms
49,424 KB
testcase_02 AC 44 ms
51,464 KB
testcase_03 AC 41 ms
49,472 KB
testcase_04 AC 42 ms
49,632 KB
testcase_05 AC 43 ms
49,488 KB
testcase_06 AC 42 ms
49,392 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;

public class No00000570_Main {
	static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	public static void main(String[] args) throws IOException {
		int a = Integer.parseInt(br.readLine());
		int b = Integer.parseInt(br.readLine());
		int c = Integer.parseInt(br.readLine());
		int[] t = {a, b, c};
		Arrays.sort(t);
		for(int i = 2; 0 <= i; i--) {
			if(t[i] == a) {
				System.out.println("A");
			} else if(t[i] == b) {
				System.out.println("B");
			} else if (t[i] == c) {
				System.out.println("C");
			}
		}
	}
}
0