結果

問題 No.251 大きな桁の復習問題(1)
ユーザー nebukuro09
提出日時 2016-10-16 13:57:23
言語 Python2
(2.7.18)
結果
TLE  
実行時間 -
コード長 202 bytes
コンパイル時間 132 ms
コンパイル使用メモリ 6,912 KB
実行使用メモリ 13,732 KB
最終ジャッジ日時 2024-11-22 11:58:13
合計ジャッジ時間 67,605 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 10 TLE * 11
権限があれば一括ダウンロードができます

ソースコード

diff #

def powermod(n, x, mod):
    ans = 1
    while x >= 1:
        if x%2:
            ans = ans * n % mod
        n = n * n % mod
        x /= 2
    return ans

print powermod(input(), input(), 129402307)
0