結果
| 問題 |
No.1665 quotient replace
|
| コンテスト | |
| ユーザー |
ntuda
|
| 提出日時 | 2021-09-04 11:58:33 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 386 bytes |
| コンパイル時間 | 323 ms |
| コンパイル使用メモリ | 82,708 KB |
| 実行使用メモリ | 325,280 KB |
| 最終ジャッジ日時 | 2024-12-17 19:48:54 |
| 合計ジャッジ時間 | 79,912 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | WA * 23 TLE * 18 |
ソースコード
def num_divisors(n):
divisors = []
for i in range(1, int(n**0.5)+1):
if n % i == 0:
divisors.append(i)
if i != n // i:
divisors.append(n//i)
return len(divisors) - 1
N = int(input())
A = list(map(int,input().split()))
G = 0
for i in range(N):
G ^= num_divisors(A[i])
if G == 0:
print("Black")
else:
print("White")
ntuda