結果
問題 | No.358 も~っと!門松列 |
ユーザー |
![]() |
提出日時 | 2019-05-21 02:00:57 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 486 bytes |
コンパイル時間 | 78 ms |
コンパイル使用メモリ | 12,928 KB |
実行使用メモリ | 11,008 KB |
最終ジャッジ日時 | 2024-09-17 08:42:39 |
合計ジャッジ時間 | 1,570 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 10 WA * 13 |
ソースコード
def is_kadomatsu(lst):if len(set(lst)) != 3:return Falsereturn min(lst) == lst[1] or max(lst) == lst[1]lst = list(map(int,input().split()))i = 2cnt = 0t_chain = 0f_chain = 0while True:if is_kadomatsu([x % i for x in lst]):cnt+=1t_chain+=1f_chain = 0else:f_chain+=1t_chain = 0if t_chain >= 100 or f_chain >= 100:breaki+=1if t_chain >= 100:ans = "INF"else:ans = cntprint(ans)