結果

問題 No.1665 quotient replace
ユーザー 👑 H20H20
提出日時 2021-09-10 12:52:55
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 362 bytes
コンパイル時間 615 ms
コンパイル使用メモリ 87,028 KB
実行使用メモリ 274,448 KB
最終ジャッジ日時 2023-08-30 23:53:01
合計ジャッジ時間 12,763 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 88 ms
83,312 KB
testcase_01 AC 90 ms
83,408 KB
testcase_02 AC 87 ms
83,480 KB
testcase_03 AC 93 ms
83,988 KB
testcase_04 AC 94 ms
84,324 KB
testcase_05 AC 88 ms
83,332 KB
testcase_06 AC 99 ms
84,420 KB
testcase_07 AC 93 ms
84,276 KB
testcase_08 AC 95 ms
84,428 KB
testcase_09 AC 105 ms
87,908 KB
testcase_10 AC 249 ms
154,848 KB
testcase_11 AC 410 ms
232,836 KB
testcase_12 AC 130 ms
101,692 KB
testcase_13 AC 507 ms
273,524 KB
testcase_14 AC 497 ms
274,448 KB
testcase_15 AC 489 ms
273,228 KB
testcase_16 AC 493 ms
273,796 KB
testcase_17 AC 501 ms
273,644 KB
testcase_18 AC 88 ms
83,468 KB
testcase_19 WA -
testcase_20 AC 88 ms
83,484 KB
testcase_21 AC 87 ms
83,480 KB
testcase_22 AC 88 ms
83,396 KB
testcase_23 WA -
testcase_24 WA -
testcase_25 AC 87 ms
83,456 KB
testcase_26 WA -
testcase_27 WA -
testcase_28 WA -
testcase_29 WA -
testcase_30 WA -
testcase_31 WA -
testcase_32 WA -
testcase_33 WA -
testcase_34 WA -
testcase_35 WA -
testcase_36 WA -
testcase_37 WA -
testcase_38 WA -
testcase_39 WA -
testcase_40 WA -
testcase_41 WA -
testcase_42 AC 87 ms
83,312 KB
testcase_43 AC 86 ms
83,212 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
A = list(map(int,input().split()))
T = [0]*(10**6+1)
for i in range(2,10**3+1):
    if T[i]==0:
        for j in range(i,10**6+1,i):
            T[j]=i

XOR = []
for a in A:
    c = 0
    while T[a]>0:
        c+=1
        a = a//T[a]
    XOR.append(c)

nim = 0
for xor in XOR:
    nim^=xor
if nim==0:
    print('black')
else:
    print('white')
0