結果

問題 No.513 宝探し2
ユーザー incuiioincuiio
提出日時 2023-05-19 06:18:08
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 795 bytes
コンパイル時間 1,359 ms
コンパイル使用メモリ 128,060 KB
実行使用メモリ 24,288 KB
平均クエリ数 2.58
最終ジャッジ日時 2023-08-22 16:27:14
合計ジャッジ時間 3,512 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 24 ms
24,204 KB
testcase_01 AC 22 ms
23,652 KB
testcase_02 AC 22 ms
24,000 KB
testcase_03 AC 23 ms
23,640 KB
testcase_04 AC 22 ms
23,412 KB
testcase_05 AC 22 ms
23,568 KB
testcase_06 AC 23 ms
23,472 KB
testcase_07 AC 22 ms
23,844 KB
testcase_08 AC 22 ms
24,000 KB
testcase_09 AC 22 ms
23,412 KB
testcase_10 WA -
testcase_11 AC 23 ms
23,844 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <fstream>
#include <iomanip>
#include <vector>
#include <algorithm>
#include <cmath>
#include <unordered_map>
#include <map>
#include <queue>
#include <string>
#include <set>
#include <list>
#include <climits>
#include <bitset>
#include <numeric>
#include <cassert>
#include <regex>
using std::cout;
using std::cin;
using std::string;
using std::vector;

int main()
{
    cout << "0 0" << std::endl;
    int d1;
    cin >> d1;
    if (d1 == 0)
    {
        return 0;
    }
    int x = std::min((int)1e5, d1);
    int y = 0;
    if (d1 > 1e5)
    {
        y = d1 % (int)1e5;
    }
    cout << x << ' ' << y << std::endl;
    int d2;
    cin >> d2;
    if (d2 == 0)
    {
        return 0;
    }
    cout << x - d2/2 << ' ' << y + d2/2 << std::endl;
    return 0;
}
0