結果

問題 No.1366 交換門松列・梅
ユーザー aaaaaaaaaa2230aaaaaaaaaa2230
提出日時 2021-01-29 22:15:32
言語 PyPy3
(7.3.13)
結果
AC  
実行時間 77 ms / 1,000 ms
コード長 368 bytes
コンパイル時間 318 ms
コンパイル使用メモリ 86,824 KB
実行使用メモリ 71,428 KB
最終ジャッジ日時 2023-07-30 09:00:58
合計ジャッジ時間 2,139 ms
ジャッジサーバーID
(参考情報)
judge13 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 77 ms
71,080 KB
testcase_01 AC 73 ms
71,420 KB
testcase_02 AC 73 ms
71,428 KB
testcase_03 AC 71 ms
71,188 KB
testcase_04 AC 72 ms
71,220 KB
testcase_05 AC 72 ms
70,936 KB
testcase_06 AC 73 ms
71,116 KB
testcase_07 AC 73 ms
71,316 KB
testcase_08 AC 77 ms
71,420 KB
testcase_09 AC 75 ms
71,288 KB
testcase_10 AC 75 ms
71,064 KB
testcase_11 AC 75 ms
71,180 KB
testcase_12 AC 72 ms
71,316 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

A = list(map(int,input().split()))
B = list(map(int,input().split()))

for i in range(3):
    for j in range(3):
        a = A.copy()
        b = B.copy()
        a[i],b[j] = b[j],a[i]
        if len(set(a)) == 3 and len(set(b)) == 3 and (min(a) == a[1] or max(a) == a[1]) and (min(b) == b[1] or max(b) == b[1]):
            print("Yes")
            exit()
print("No")
0