結果

問題 No.3029 素因数
ユーザー 👑 kmjpkmjp
提出日時 2017-03-31 23:29:45
言語 Python2
(2.7.18)
結果
RE  
実行時間 -
コード長 276 bytes
コンパイル時間 69 ms
コンパイル使用メモリ 6,720 KB
実行使用メモリ 6,184 KB
最終ジャッジ日時 2023-09-21 12:09:05
合計ジャッジ時間 2,002 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 10 ms
6,052 KB
testcase_01 RE -
testcase_02 AC 10 ms
6,008 KB
testcase_03 AC 10 ms
6,032 KB
testcase_04 AC 10 ms
5,984 KB
testcase_05 RE -
testcase_06 AC 11 ms
6,040 KB
testcase_07 AC 10 ms
5,948 KB
testcase_08 RE -
testcase_09 AC 10 ms
6,144 KB
testcase_10 RE -
testcase_11 AC 10 ms
6,056 KB
testcase_12 RE -
testcase_13 RE -
testcase_14 RE -
testcase_15 RE -
testcase_16 AC 11 ms
6,008 KB
testcase_17 RE -
testcase_18 AC 10 ms
5,944 KB
testcase_19 WA -
testcase_20 AC 10 ms
6,052 KB
testcase_21 AC 10 ms
5,952 KB
testcase_22 RE -
testcase_23 RE -
testcase_24 RE -
testcase_25 AC 10 ms
6,084 KB
testcase_26 WA -
testcase_27 RE -
testcase_28 AC 10 ms
5,960 KB
testcase_29 AC 11 ms
6,008 KB
testcase_30 RE -
testcase_31 AC 10 ms
5,960 KB
testcase_32 RE -
testcase_33 AC 11 ms
6,088 KB
testcase_34 AC 10 ms
6,120 KB
testcase_35 AC 10 ms
5,940 KB
testcase_36 RE -
testcase_37 RE -
testcase_38 RE -
testcase_39 AC 10 ms
6,020 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

A=1309020564363155364990198847863210152708042104341971929
M=input()

if M==1:
	print "even"
else:
	D=1
	while M%2==0:
		M /= 2
		D *= 2

	if M==1:
		print "odd"
	else:
		MM=A%M
		while D>1 and MM%2==0:
			MM /= 2
			D /= 2

		if MM%2==0:
			assert 0
		else:
			print "odd"


0