結果

問題 No.36 素数が嫌い!
ユーザー human_cipher
提出日時 2021-06-22 01:38:04
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
TLE  
(最新)
AC  
(最初)
実行時間 -
コード長 302 bytes
コンパイル時間 105 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 11,008 KB
最終ジャッジ日時 2024-06-22 23:01:48
合計ジャッジ時間 25,005 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 24 TLE * 2
権限があれば一括ダウンロードができます

ソースコード

diff #

from math import sqrt

n = int(input())

div = 2
fact = list()
while div < int(sqrt(n))+1 and n > 1:
    if n % div == 0:
        while n % div == 0:
            fact.append(div)
            n //= div
    div += 1
if n > 1:
    fact.append(n)

if len(fact) >= 3:
    print("YES")
else:
    print("NO")
0