結果

問題 No.1665 quotient replace
ユーザー nikumakarenikumakare
提出日時 2021-12-09 23:27:16
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 2,679 ms / 3,000 ms
コード長 438 bytes
コンパイル時間 247 ms
コンパイル使用メモリ 86,788 KB
実行使用メモリ 184,140 KB
最終ジャッジ日時 2023-09-24 15:41:59
合計ジャッジ時間 40,784 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 73 ms
75,168 KB
testcase_01 AC 74 ms
75,452 KB
testcase_02 AC 74 ms
75,296 KB
testcase_03 AC 81 ms
76,004 KB
testcase_04 AC 84 ms
76,116 KB
testcase_05 AC 77 ms
75,692 KB
testcase_06 AC 103 ms
76,196 KB
testcase_07 AC 87 ms
76,408 KB
testcase_08 AC 95 ms
76,304 KB
testcase_09 AC 161 ms
78,156 KB
testcase_10 AC 956 ms
102,664 KB
testcase_11 AC 2,045 ms
160,680 KB
testcase_12 AC 298 ms
83,576 KB
testcase_13 AC 2,679 ms
184,140 KB
testcase_14 AC 2,666 ms
182,896 KB
testcase_15 AC 2,666 ms
183,204 KB
testcase_16 AC 2,652 ms
183,560 KB
testcase_17 AC 2,657 ms
183,912 KB
testcase_18 AC 74 ms
75,372 KB
testcase_19 AC 71 ms
75,428 KB
testcase_20 AC 74 ms
75,312 KB
testcase_21 AC 73 ms
75,436 KB
testcase_22 AC 73 ms
75,436 KB
testcase_23 AC 73 ms
75,204 KB
testcase_24 AC 77 ms
75,508 KB
testcase_25 AC 76 ms
75,208 KB
testcase_26 AC 87 ms
76,124 KB
testcase_27 AC 99 ms
75,920 KB
testcase_28 AC 180 ms
78,384 KB
testcase_29 AC 285 ms
81,932 KB
testcase_30 AC 1,617 ms
129,524 KB
testcase_31 AC 2,436 ms
154,576 KB
testcase_32 AC 1,950 ms
151,436 KB
testcase_33 AC 802 ms
106,752 KB
testcase_34 AC 1,585 ms
141,492 KB
testcase_35 AC 1,460 ms
132,752 KB
testcase_36 AC 1,534 ms
139,088 KB
testcase_37 AC 1,397 ms
129,736 KB
testcase_38 AC 1,670 ms
149,580 KB
testcase_39 AC 1,186 ms
118,336 KB
testcase_40 AC 1,199 ms
118,432 KB
testcase_41 AC 1,193 ms
118,440 KB
testcase_42 AC 74 ms
75,168 KB
testcase_43 AC 72 ms
75,192 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
A=[int(i) for i in input().split()]
ans=0
sosu=[]
fu=[0 for i in range(1001)]
for i in range(2,1001):
    if fu[i]==0:
        sosu.append(i)
        for q in range(i,1001,i):
            fu[q]=1

for num in A:
    sub=0
    for i in sosu:
        while num%i==0:
            num//=i
            sub+=1
        if num==1:
            break
    if num>1:
        sub+=1
    ans^=sub
print("white") if ans else print("black")
0