結果
問題 |
No.300 平方数
|
ユーザー |
|
提出日時 | 2019-08-02 16:22:23 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 345 bytes |
コンパイル時間 | 77 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 10,880 KB |
最終ジャッジ日時 | 2024-07-05 08:08:40 |
合計ジャッジ時間 | 7,042 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 WA * 1 |
other | AC * 13 WA * 30 |
ソースコード
x = int(input()) d = {} for i in range(2, int(x**0.5)+1): while x % i == 0: if not i in d: d[i] = 1 else: d[i] += 1 x //= i if x > 1: d[x] = 1 if len(d) == 0: print(x) else: y = 1 for k, v in d.items(): if int(v) % 2 != 0: y *= int(k) print(y)