結果
| 問題 |
No.570 3人兄弟(その1)
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-10-07 11:05:17 |
| 言語 | Java (openjdk 23) |
| 結果 |
AC
|
| 実行時間 | 132 ms / 2,000 ms |
| コード長 | 1,120 bytes |
| コンパイル時間 | 3,555 ms |
| コンパイル使用メモリ | 77,724 KB |
| 実行使用メモリ | 41,376 KB |
| 最終ジャッジ日時 | 2024-11-17 04:23:16 |
| 合計ジャッジ時間 | 5,051 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 5 |
ソースコード
import java.io.*;
import java.util.*;
public class Main_yukicoder570 {
private static Scanner sc;
private static Printer pr;
private static void solve() {
int ha = sc.nextInt();
int hb = sc.nextInt();
int hc = sc.nextInt();
if (ha > hb && hb > hc) {
pr.println('A');
pr.println('B');
pr.println('C');
} else if (ha > hc && hc > hb) {
pr.println('A');
pr.println('C');
pr.println('B');
} else if (hb > ha && ha > hc) {
pr.println('B');
pr.println('A');
pr.println('C');
} else if (hb > hc && hc > ha) {
pr.println('B');
pr.println('C');
pr.println('A');
} else if (hc > ha && ha > hb) {
pr.println('C');
pr.println('A');
pr.println('B');
} else if (hc > hb && hb > ha) {
pr.println('C');
pr.println('B');
pr.println('A');
}
}
// ---------------------------------------------------
public static void main(String[] args) {
sc = new Scanner(System.in);
pr = new Printer(System.out);
solve();
pr.close();
sc.close();
}
private static class Printer extends PrintWriter {
Printer(PrintStream out) {
super(out);
}
}
}