結果

問題 No.870 無敵囲い
ユーザー Schnee
提出日時 2022-10-15 04:11:49
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 30 ms / 300 ms
コード長 336 bytes
コンパイル時間 92 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 10,880 KB
最終ジャッジ日時 2024-06-26 19:21:55
合計ジャッジ時間 1,429 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 18
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
a, b, c = [2, 8], [3, 9], [7, 9]
for _ in "_"*n:
    x1, y1, x2, y2 = map(int, input().split())
    if a[0] == x1 and a[1] == y1:
        a = [x2, y2]
    elif b[0] == x1 and b[1] == y1:
        b = [x2, y2]
    elif c[0] == x1 and c[1] == y1:
        c = [x2, y2]
print("YNEOS"[a!=[5, 8] or b!=[4, 8] or c!=[6, 8]::2])
0