結果

問題 No.514 宝探し3
ユーザー takeya_okinotakeya_okino
提出日時 2019-08-31 02:13:47
言語 Java19
(openjdk 21)
結果
AC  
実行時間 198 ms / 2,000 ms
コード長 495 bytes
コンパイル時間 2,542 ms
コンパイル使用メモリ 73,760 KB
実行使用メモリ 72,932 KB
平均クエリ数 2.67
最終ジャッジ日時 2023-09-23 18:12:56
合計ジャッジ時間 5,488 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 182 ms
72,852 KB
testcase_01 AC 190 ms
72,780 KB
testcase_02 AC 186 ms
72,932 KB
testcase_03 AC 182 ms
72,632 KB
testcase_04 AC 187 ms
72,108 KB
testcase_05 AC 169 ms
72,212 KB
testcase_06 AC 193 ms
72,776 KB
testcase_07 AC 187 ms
72,428 KB
testcase_08 AC 152 ms
69,320 KB
testcase_09 AC 167 ms
71,912 KB
testcase_10 AC 187 ms
72,408 KB
testcase_11 AC 198 ms
72,684 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    System.out.println(0 + " " + 0);
    System.out.flush();
    long R = sc.nextLong();
    if(R == 0) System.exit(0);
    System.out.println(R + " " + 0);
    System.out.flush();
    long a = sc.nextLong();
    if(a == 0) System.exit(0);
    System.out.println((R - a / 2) + " " + (a / 2));
    System.out.flush();
    long b = sc.nextLong();
    System.exit(0);
  }
}
0