結果
問題 | No.361 門松ゲーム2 |
ユーザー |
![]() |
提出日時 | 2020-09-26 03:09:16 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 289 ms / 2,000 ms |
コード長 | 497 bytes |
コンパイル時間 | 153 ms |
コンパイル使用メモリ | 82,300 KB |
実行使用メモリ | 73,748 KB |
最終ジャッジ日時 | 2024-06-28 12:05:54 |
合計ジャッジ時間 | 4,522 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 28 |
ソースコード
import sysread=sys.stdin.buffer.readreadline=sys.stdin.buffer.readlinereadlines=sys.stdin.buffer.readlinesl, d=map(int, readline().split())g=[0]*(l+1)for x in range(1, l+1):st=set()for a in range(1, x):for b in range(1, a):c=x-a-bif 0<c and c<b and a-c<=d:st.add(g[a]^g[b]^g[c])i=0while True:if i not in st:g[x]=ibreaki+=1if g[l]:print("kado")else:print("matsu")