結果

問題 No.312 置換処理
ユーザー kawacchukawacchu
提出日時 2019-11-13 00:35:15
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 383 bytes
コンパイル時間 146 ms
コンパイル使用メモリ 11,888 KB
実行使用メモリ 10,024 KB
最終ジャッジ日時 2023-10-19 20:45:23
合計ジャッジ時間 3,069 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 33 ms
10,024 KB
testcase_01 AC 75 ms
10,024 KB
testcase_02 AC 125 ms
10,024 KB
testcase_03 AC 97 ms
10,024 KB
testcase_04 AC 30 ms
10,024 KB
testcase_05 AC 30 ms
10,024 KB
testcase_06 AC 35 ms
10,024 KB
testcase_07 AC 56 ms
10,024 KB
testcase_08 AC 33 ms
10,024 KB
testcase_09 AC 36 ms
10,024 KB
testcase_10 AC 30 ms
10,024 KB
testcase_11 AC 39 ms
10,024 KB
testcase_12 AC 29 ms
10,024 KB
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 WA -
testcase_21 WA -
testcase_22 AC 29 ms
10,024 KB
testcase_23 WA -
testcase_24 AC 29 ms
10,024 KB
testcase_25 AC 29 ms
10,024 KB
testcase_26 AC 29 ms
10,024 KB
testcase_27 WA -
testcase_28 AC 29 ms
10,024 KB
testcase_29 AC 29 ms
10,024 KB
testcase_30 AC 38 ms
10,024 KB
testcase_31 WA -
testcase_32 AC 38 ms
10,024 KB
testcase_33 AC 58 ms
10,024 KB
testcase_34 AC 59 ms
10,024 KB
testcase_35 AC 31 ms
10,024 KB
testcase_36 AC 29 ms
10,024 KB
testcase_37 AC 29 ms
10,024 KB
testcase_38 WA -
testcase_39 AC 28 ms
10,024 KB
testcase_40 AC 29 ms
10,024 KB
testcase_41 AC 29 ms
10,024 KB
testcase_42 AC 29 ms
10,024 KB
testcase_43 AC 29 ms
10,024 KB
testcase_44 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

def trial_division(n) :
    a = []
    while (n % 2 == 0) :
        a.append(2)
        n //= 2
    f = 3
    while (f ** 2 <= n) :
        if n % f == 0 :
            a.append(f)
            n //= f
        else :
            f += 2
    if n != 1 : a.append(n)
    return a

a = trial_division(int(input()))

a = sorted(a)
for i in a :
    if i > 2 :
        print(i)
        break
0