結果
問題 | No.2044 Infinite Nim |
ユーザー |
![]() |
提出日時 | 2022-08-19 21:38:38 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 207 bytes |
コンパイル時間 | 313 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 21,648 KB |
最終ジャッジ日時 | 2024-10-08 07:52:30 |
合計ジャッジ時間 | 2,710 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 28 WA * 6 |
ソースコード
n = int(input()) a = list(map(int, input().split())) m = a.count(-1) if m%2: print("First") elif m > 0: print("Second") else: for i in range(n-1): a[i+1] ^= a[i] print("First" if a[-1] else "Second")