結果
問題 |
No.201 yukicoderじゃんけん
|
ユーザー |
|
提出日時 | 2018-02-06 13:11:42 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 104 ms / 5,000 ms |
コード長 | 668 bytes |
コンパイル時間 | 3,377 ms |
コンパイル使用メモリ | 75,144 KB |
実行使用メモリ | 52,200 KB |
最終ジャッジ日時 | 2024-07-18 00:58:21 |
合計ジャッジ時間 | 4,654 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 |
ソースコード
package me.yukicoder.lv1_5; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.math.BigInteger; public class No0201 { public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); String[] inputA = br.readLine().split(" "); String[] inputB = br.readLine().split(" "); BigInteger a = new BigInteger(inputA[1]); BigInteger b = new BigInteger(inputB[1]); if (a.compareTo(b) > 0) { System.out.println(inputA[0]); } else if (a.compareTo(b) < 0) { System.out.println(inputB[0]); } else { System.out.println(-1); } } }