結果
| 問題 | No.715 集合と二人ゲーム |
| コンテスト | |
| ユーザー |
simamumu
|
| 提出日時 | 2018-07-13 23:15:44 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 513 bytes |
| 記録 | |
| コンパイル時間 | 181 ms |
| コンパイル使用メモリ | 12,800 KB |
| 実行使用メモリ | 65,488 KB |
| 最終ジャッジ日時 | 2024-10-09 05:35:37 |
| 合計ジャッジ時間 | 8,216 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 30 WA * 30 |
ソースコード
from collections import defaultdict
import sys,heapq,bisect,math,itertools,string
N = int(input())
aa = list(map(int,input().split()))
aa.sort()
li = []
num = 1
for i in range(N-1):
if aa[i+1]-aa[i] == 1:
num += 1
else:
li.append(num)
num = 1
li.append(num)
ans = 0
while 4 in li:
li.remove(4)
while 1 in li:
ans += 1
li.remove(1)
while 2 in li:
ans += 1
li.remove(2)
for i in li:
if i < 8 or i%2 == 1:
print('First')
sys.exit()
if ans%2 == 0:
print('Second')
else:
print('First')
simamumu