結果

問題 No.300 平方数
ユーザー ayame_pyayame_py
提出日時 2015-11-13 23:06:53
言語 Python2
(2.7.18)
結果
WA  
実行時間 -
コード長 237 bytes
コンパイル時間 494 ms
コンパイル使用メモリ 6,720 KB
実行使用メモリ 37,876 KB
最終ジャッジ日時 2023-10-11 16:24:48
合計ジャッジ時間 5,606 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 12 ms
6,096 KB
testcase_01 AC 12 ms
6,060 KB
testcase_02 AC 98 ms
27,348 KB
testcase_03 AC 12 ms
6,096 KB
testcase_04 AC 11 ms
6,096 KB
testcase_05 WA -
testcase_06 AC 11 ms
6,032 KB
testcase_07 AC 12 ms
6,224 KB
testcase_08 AC 11 ms
6,116 KB
testcase_09 AC 12 ms
6,032 KB
testcase_10 AC 12 ms
6,028 KB
testcase_11 AC 11 ms
6,140 KB
testcase_12 AC 13 ms
6,412 KB
testcase_13 WA -
testcase_14 AC 24 ms
8,864 KB
testcase_15 AC 76 ms
21,992 KB
testcase_16 AC 68 ms
20,140 KB
testcase_17 AC 137 ms
37,856 KB
testcase_18 AC 22 ms
8,408 KB
testcase_19 AC 60 ms
17,868 KB
testcase_20 WA -
testcase_21 AC 138 ms
37,876 KB
testcase_22 AC 124 ms
33,920 KB
testcase_23 WA -
testcase_24 WA -
testcase_25 AC 116 ms
31,612 KB
testcase_26 WA -
testcase_27 WA -
testcase_28 AC 114 ms
31,240 KB
testcase_29 WA -
testcase_30 WA -
testcase_31 WA -
testcase_32 WA -
testcase_33 AC 56 ms
16,256 KB
testcase_34 AC 124 ms
34,080 KB
testcase_35 AC 87 ms
24,464 KB
testcase_36 WA -
testcase_37 WA -
testcase_38 AC 97 ms
27,084 KB
testcase_39 WA -
testcase_40 WA -
testcase_41 WA -
testcase_42 AC 85 ms
24,360 KB
testcase_43 WA -
testcase_44 WA -
testcase_45 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

# coding: utf-8
import math
X=input()
N=X
prime = 1
ans = 1
for i in range(2,int(math.sqrt(X))+2):
	if(N%i==0):
		prime = 0
		count = 0
		while(N%i==0):
			N/=i
			count+=1
		if count%2==1: ans*=i

if prime == 1: print X
else: print ans
0