結果

問題 No.870 無敵囲い
ユーザー roarisroaris
提出日時 2019-08-30 21:24:50
言語 PyPy3
(7.3.13)
結果
AC  
実行時間 69 ms / 300 ms
コード長 358 bytes
コンパイル時間 264 ms
コンパイル使用メモリ 87,068 KB
実行使用メモリ 71,168 KB
最終ジャッジ日時 2023-09-11 16:06:09
合計ジャッジ時間 2,683 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 68 ms
71,044 KB
testcase_01 AC 67 ms
71,168 KB
testcase_02 AC 67 ms
70,784 KB
testcase_03 AC 65 ms
70,980 KB
testcase_04 AC 69 ms
70,932 KB
testcase_05 AC 65 ms
70,792 KB
testcase_06 AC 65 ms
70,984 KB
testcase_07 AC 64 ms
71,024 KB
testcase_08 AC 65 ms
71,020 KB
testcase_09 AC 65 ms
70,792 KB
testcase_10 AC 67 ms
70,936 KB
testcase_11 AC 67 ms
70,988 KB
testcase_12 AC 66 ms
71,072 KB
testcase_13 AC 68 ms
71,060 KB
testcase_14 AC 68 ms
71,044 KB
testcase_15 AC 67 ms
70,792 KB
testcase_16 AC 68 ms
70,872 KB
testcase_17 AC 68 ms
71,088 KB
testcase_18 AC 67 ms
70,868 KB
testcase_19 AC 67 ms
70,996 KB
testcase_20 AC 69 ms
71,100 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
A, B, C = [2, 8], [3, 9], [7, 9]

for _ in range(N):
    xi1, yi1, xi2, yi2 = map(int, input().split())
    
    if A == [xi1, yi1]:
        A = [xi2, yi2]
    elif B == [xi1, yi1]:
        B = [xi2, yi2]
    elif C == [xi1, yi1]:
        C = [xi2, yi2]

if A == [5, 8] and B == [4, 8] and C == [6, 8]:
    print('YES')
else:
    print('NO')
0