結果

問題 No.1149 色塗りゲーム
ユーザー shotoyooshotoyoo
提出日時 2020-08-15 00:10:31
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 170 ms / 2,000 ms
コード長 454 bytes
コンパイル時間 232 ms
コンパイル使用メモリ 87,008 KB
実行使用メモリ 87,688 KB
平均クエリ数 19.82
最終ジャッジ日時 2023-09-24 05:36:30
合計ジャッジ時間 8,670 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 103 ms
87,144 KB
testcase_01 AC 95 ms
87,204 KB
testcase_02 AC 98 ms
87,096 KB
testcase_03 AC 95 ms
87,664 KB
testcase_04 AC 95 ms
87,640 KB
testcase_05 AC 96 ms
87,304 KB
testcase_06 AC 95 ms
87,108 KB
testcase_07 AC 98 ms
87,228 KB
testcase_08 AC 100 ms
87,280 KB
testcase_09 AC 94 ms
87,360 KB
testcase_10 AC 108 ms
87,212 KB
testcase_11 AC 105 ms
87,128 KB
testcase_12 AC 109 ms
87,352 KB
testcase_13 AC 105 ms
87,252 KB
testcase_14 AC 101 ms
87,028 KB
testcase_15 AC 99 ms
87,168 KB
testcase_16 AC 102 ms
87,244 KB
testcase_17 AC 101 ms
86,984 KB
testcase_18 AC 100 ms
86,960 KB
testcase_19 AC 98 ms
87,436 KB
testcase_20 AC 99 ms
87,144 KB
testcase_21 AC 99 ms
87,384 KB
testcase_22 AC 99 ms
87,304 KB
testcase_23 AC 99 ms
87,120 KB
testcase_24 AC 100 ms
87,312 KB
testcase_25 AC 99 ms
87,196 KB
testcase_26 AC 98 ms
87,532 KB
testcase_27 AC 98 ms
87,372 KB
testcase_28 AC 100 ms
86,832 KB
testcase_29 AC 104 ms
86,708 KB
testcase_30 AC 136 ms
87,120 KB
testcase_31 AC 132 ms
87,420 KB
testcase_32 AC 134 ms
87,652 KB
testcase_33 AC 135 ms
87,328 KB
testcase_34 AC 141 ms
87,160 KB
testcase_35 AC 137 ms
87,356 KB
testcase_36 AC 142 ms
87,416 KB
testcase_37 AC 145 ms
87,120 KB
testcase_38 AC 141 ms
87,328 KB
testcase_39 AC 144 ms
87,384 KB
testcase_40 AC 152 ms
87,384 KB
testcase_41 AC 146 ms
87,524 KB
testcase_42 AC 144 ms
87,204 KB
testcase_43 AC 143 ms
87,272 KB
testcase_44 AC 155 ms
87,264 KB
testcase_45 AC 170 ms
87,632 KB
testcase_46 AC 160 ms
87,688 KB
testcase_47 AC 159 ms
87,288 KB
testcase_48 AC 158 ms
86,684 KB
testcase_49 AC 161 ms
87,616 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = lambda : sys.stdin.readline().rstrip()
sys.setrecursionlimit(max(1000, 10**9))
write = lambda x: sys.stdout.write(x+"\n")


def out(k,x):
    print(" ".join(map(str, (k,x))))
    import sys
    sys.stdout.flush()
n = int(input())
if n%2==0:
    out(2, n//2)
else:
    out(1, n//2+1)
while True:
    t = int(input())
    if t in (0,1):
        break
    k,x = map(int, input().split())
    if t==2:
        break
    out(k, n+1-x-(k-1))
0