結果

問題 No.201 yukicoderじゃんけん
ユーザー takeya_okinotakeya_okino
提出日時 2017-06-22 09:52:58
言語 Java21
(openjdk 21)
結果
AC  
実行時間 187 ms / 5,000 ms
コード長 544 bytes
コンパイル時間 2,160 ms
コンパイル使用メモリ 75,000 KB
実行使用メモリ 54,768 KB
最終ジャッジ日時 2024-04-10 08:20:27
合計ジャッジ時間 5,385 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 113 ms
54,120 KB
testcase_01 AC 112 ms
54,104 KB
testcase_02 AC 112 ms
53,884 KB
testcase_03 AC 119 ms
53,960 KB
testcase_04 AC 105 ms
52,988 KB
testcase_05 AC 104 ms
53,016 KB
testcase_06 AC 118 ms
53,948 KB
testcase_07 AC 114 ms
54,028 KB
testcase_08 AC 108 ms
53,976 KB
testcase_09 AC 120 ms
54,248 KB
testcase_10 AC 119 ms
53,952 KB
testcase_11 AC 120 ms
53,828 KB
testcase_12 AC 115 ms
53,752 KB
testcase_13 AC 117 ms
53,976 KB
testcase_14 AC 106 ms
52,860 KB
testcase_15 AC 168 ms
54,068 KB
testcase_16 AC 157 ms
54,132 KB
testcase_17 AC 158 ms
54,012 KB
testcase_18 AC 158 ms
53,944 KB
testcase_19 AC 187 ms
54,768 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;
import java.math.BigInteger;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    String sa = sc.next();
    String pa = sc.next();
    String xa = sc.next();
    String sb = sc.next();
    String pb = sc.next();
    String xb = sc.next();
    BigInteger num1 = new BigInteger(pa);
    BigInteger num2 = new BigInteger(pb);
    String ans = "-1";
    if(num1.compareTo(num2) > 0) ans = sa;
    if(num1.compareTo(num2) < 0) ans = sb;
    System.out.println(ans);
  }
}
0