結果

問題 No.36 素数が嫌い!
ユーザー neko_the_shadowneko_the_shadow
提出日時 2016-08-28 00:01:44
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 242 bytes
コンパイル時間 178 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 11,008 KB
最終ジャッジ日時 2024-04-26 07:05:04
合計ジャッジ時間 21,731 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 1,227 ms
10,496 KB
testcase_02 AC 31 ms
10,752 KB
testcase_03 AC 31 ms
10,752 KB
testcase_04 AC 30 ms
10,752 KB
testcase_05 AC 34 ms
10,752 KB
testcase_06 AC 37 ms
10,752 KB
testcase_07 AC 35 ms
10,752 KB
testcase_08 AC 31 ms
10,624 KB
testcase_09 AC 33 ms
10,624 KB
testcase_10 WA -
testcase_11 AC 581 ms
10,880 KB
testcase_12 AC 1,640 ms
10,752 KB
testcase_13 AC 1,678 ms
10,624 KB
testcase_14 AC 837 ms
10,752 KB
testcase_15 AC 32 ms
10,624 KB
testcase_16 AC 30 ms
10,752 KB
testcase_17 AC 31 ms
10,624 KB
testcase_18 AC 31 ms
10,624 KB
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 WA -
testcase_24 AC 742 ms
10,752 KB
testcase_25 WA -
testcase_26 AC 1,002 ms
10,752 KB
testcase_27 AC 1,402 ms
10,624 KB
testcase_28 AC 1,007 ms
10,752 KB
testcase_29 AC 1,621 ms
10,496 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import math

if __name__ == '__main__':
    n = int(input())

    cnt = 0
    for prime in range(2, int(math.sqrt(n)) + 1):
        while n % prime == 0:
            n //= prime
            cnt += 1
    
    print("YES" if cnt >= 3 else "NO")
0