結果
| 問題 | No.2379 Burnside's Theorem |
| コンテスト | |
| ユーザー |
ntuda
|
| 提出日時 | 2023-07-15 10:39:48 |
| 言語 | PyPy3 (7.3.23 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 82 ms / 2,000 ms |
| + 49µs | |
| コード長 | 460 bytes |
| 記録 | |
| コンパイル時間 | 247 ms |
| コンパイル使用メモリ | 96,112 KB |
| 実行使用メモリ | 83,456 KB |
| 最終ジャッジ日時 | 2026-08-29 01:15:36 |
| 合計ジャッジ時間 | 3,759 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 20 |
ソースコード
import collections
def prime_factorize(n):
a = []
while n % 2 == 0:
a.append(2)
n //= 2
f = 3
while f * f <= n:
if n % f == 0:
a.append(f)
n //= f
else:
f += 2
if n != 1:
a.append(n)
return a
def n_fact(N):
c = collections.Counter(prime_factorize(N))
return c
N = int(input())
dic = n_fact(N)
if len(dic) <= 2:
print("Yes")
else:
print("No")
ntuda