結果

問題 No.1366 交換門松列・梅
ユーザー marroncastle
提出日時 2021-01-29 21:24:18
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 345 bytes
コンパイル時間 151 ms
コンパイル使用メモリ 82,448 KB
実行使用メモリ 53,448 KB
最終ジャッジ日時 2024-06-27 07:29:51
合計ジャッジ時間 1,272 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 6 WA * 5
権限があれば一括ダウンロードができます

ソースコード

diff #

def check(A):
  if (A[1]-A[0])*(A[2]-A[1])>0: return True
  return False

def solve():
  A = list(map(int, input().split()))
  B = list(map(int, input().split()))
  for i in range(3):
    for j in range(3):
      C = A[:]; D = B[:]
      C[i], D[j] = D[j], C[i]
      if check(C) and check(D):
        return 'Yes'
  return 'No'
print(solve())

0