結果

問題 No.2380 Sylow P-subgroup
ユーザー ntudantuda
提出日時 2023-07-15 10:53:53
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 70 ms / 2,000 ms
コード長 131 bytes
コンパイル時間 266 ms
コンパイル使用メモリ 86,568 KB
実行使用メモリ 71,284 KB
最終ジャッジ日時 2023-10-15 01:40:53
合計ジャッジ時間 2,248 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 67 ms
71,124 KB
testcase_01 AC 65 ms
71,284 KB
testcase_02 AC 66 ms
71,220 KB
testcase_03 AC 68 ms
70,928 KB
testcase_04 AC 69 ms
71,236 KB
testcase_05 AC 68 ms
70,932 KB
testcase_06 AC 68 ms
71,120 KB
testcase_07 AC 68 ms
71,076 KB
testcase_08 AC 66 ms
71,024 KB
testcase_09 AC 65 ms
70,812 KB
testcase_10 AC 67 ms
70,948 KB
testcase_11 AC 70 ms
71,172 KB
testcase_12 AC 69 ms
71,128 KB
testcase_13 AC 68 ms
71,144 KB
testcase_14 AC 69 ms
71,216 KB
testcase_15 AC 69 ms
71,076 KB
testcase_16 AC 69 ms
71,260 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

MOD = 998244353
N,P = map(int,input().split())
e = 0
x = 1
while P ** x <= N:
    e += N // (P ** x)
    x += 1
print(pow(P,e,MOD))
0