結果
| 問題 |
No.167 N^M mod 10
|
| ユーザー |
ntuda
|
| 提出日時 | 2024-01-05 13:15:18 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 119 bytes |
| コンパイル時間 | 227 ms |
| コンパイル使用メモリ | 82,288 KB |
| 実行使用メモリ | 53,276 KB |
| 最終ジャッジ日時 | 2024-09-27 19:02:26 |
| 合計ジャッジ時間 | 2,220 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 25 WA * 2 |
ソースコード
N = int(input()[-1])
M = input()
if M == "0":
print(0)
exit()
M = (int(M[-2:])-1) % 100 + 1
print(pow(N,M,10))
ntuda