結果
| 問題 | No.36 素数が嫌い! |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2016-10-27 14:20:00 |
| 言語 | PyPy2 (7.3.20) |
| 結果 |
AC
|
| 実行時間 | 78 ms / 5,000 ms |
| + 72µs | |
| コード長 | 251 bytes |
| 記録 | |
| コンパイル時間 | 1,468 ms |
| コンパイル使用メモリ | 80,208 KB |
| 実行使用メモリ | 82,168 KB |
| 最終ジャッジ日時 | 2026-07-30 20:00:46 |
| 合計ジャッジ時間 | 3,953 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 26 |
ソースコード
import math
N = input()
rootN = int(math.sqrt(N))
i = 2
c = 0
while i <= rootN:
while N % i == 0:
N /= i
c += 1
if c > 2:
print 'YES'
exit()
i += 1
if c == 2 and N > 1:
print 'YES'
else:
print 'NO'