結果

問題 No.36 素数が嫌い!
コンテスト
ユーザー Makorominiris
提出日時 2016-05-30 13:36:46
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
TLE  
実行時間 -
コード長 300 bytes
コンパイル時間 322 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 13,632 KB
最終ジャッジ日時 2024-10-07 17:59:13
合計ジャッジ時間 7,035 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample -- * 4
other AC * 1 TLE * 1 -- * 24
権限があれば一括ダウンロードができます

ソースコード

diff #

N=int(input())
f=False
P=[2]
if N!=1 and N!=2:
  for j in range(3,int(N**0.5)):
    p=False
    k=0
    u=j**0.5
    for v in P:
      if v>u: break
      if j%v==0:
        p=True
        break
    if p:
      if N%j==0:
        f=True
        break
    else: P.append(j)
print("YES" if f else "NO")
0