結果

問題 No.1177 余りは?
ユーザー 37zigen37zigen
提出日時 2020-08-22 07:22:11
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 137 bytes
コンパイル時間 116 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 12,456 KB
最終ジャッジ日時 2024-04-23 06:58:10
合計ジャッジ時間 10,651 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 208 ms
11,392 KB
testcase_01 AC 829 ms
12,456 KB
testcase_02 AC 145 ms
11,136 KB
testcase_03 AC 478 ms
11,892 KB
testcase_04 AC 200 ms
11,392 KB
testcase_05 AC 301 ms
11,520 KB
testcase_06 AC 56 ms
11,008 KB
testcase_07 AC 53 ms
11,008 KB
testcase_08 AC 640 ms
12,280 KB
testcase_09 AC 531 ms
12,096 KB
testcase_10 AC 28 ms
10,880 KB
testcase_11 AC 310 ms
11,636 KB
testcase_12 AC 46 ms
11,008 KB
testcase_13 AC 78 ms
11,008 KB
testcase_14 AC 108 ms
11,136 KB
testcase_15 AC 176 ms
11,264 KB
testcase_16 AC 124 ms
11,136 KB
testcase_17 AC 671 ms
12,284 KB
testcase_18 AC 234 ms
11,392 KB
testcase_19 AC 409 ms
11,896 KB
testcase_20 AC 80 ms
11,008 KB
testcase_21 AC 328 ms
11,640 KB
testcase_22 AC 599 ms
12,148 KB
testcase_23 AC 244 ms
11,516 KB
testcase_24 AC 131 ms
11,136 KB
testcase_25 AC 488 ms
12,048 KB
testcase_26 AC 618 ms
12,148 KB
testcase_27 AC 80 ms
11,008 KB
testcase_28 AC 315 ms
11,636 KB
testcase_29 AC 273 ms
11,512 KB
testcase_30 AC 262 ms
11,520 KB
testcase_31 AC 399 ms
11,896 KB
testcase_32 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

MOD=10**9+7
p,k=map(int,input().split())
ans=((pow(10,p-1)-1)+1)//p%MOD
if pow(10,p-1)%p!=p-1 and pow(10,p-1)%p==k:
    ans+=1
print(ans)
0