結果
| 問題 |
No.360 増加門松列
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-08-28 19:38:32 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 74 ms / 2,000 ms |
| コード長 | 379 bytes |
| コンパイル時間 | 169 ms |
| コンパイル使用メモリ | 82,120 KB |
| 実行使用メモリ | 76,020 KB |
| 最終ジャッジ日時 | 2024-11-17 16:28:30 |
| 合計ジャッジ時間 | 2,405 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 22 |
ソースコード
from itertools import permutations
D = list(map(int, input().split()))
for l in permutations(D):
for i in range(5):
sub_l = [l[i], l[i+1], l[i+2]]
if l[i+1] in [min(sub_l), max(sub_l)] and l[i] < l[i+2] and 3 == len(set(sub_l)):
continue
else:
break
else:
print('YES')
break
else:
print('NO')