結果
問題 |
No.513 宝探し2
|
ユーザー |
![]() |
提出日時 | 2019-08-05 22:17:01 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 181 ms / 2,000 ms |
コード長 | 506 bytes |
コンパイル時間 | 2,302 ms |
コンパイル使用メモリ | 76,288 KB |
実行使用メモリ | 71,956 KB |
平均クエリ数 | 2.75 |
最終ジャッジ日時 | 2024-07-17 02:20:13 |
合計ジャッジ時間 | 5,411 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 12 |
ソースコード
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(); int ret1 = sc.nextInt(); if(ret1 == 0) System.exit(0); System.out.println(0 + " " + 100000); System.out.flush(); int ret2 = sc.nextInt(); if(ret2 == 0) System.exit(0); int x = (ret1 + ret2 - 100000) / 2; int y = ret1 - x; System.out.println(x + " " + y); System.out.flush(); } }