結果

問題 No.25 有限小数
ユーザー convexineqconvexineq
提出日時 2020-11-22 06:05:48
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 205 bytes
コンパイル時間 309 ms
コンパイル使用メモリ 87,192 KB
実行使用メモリ 71,780 KB
最終ジャッジ日時 2023-09-30 22:30:20
合計ジャッジ時間 4,214 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 75 ms
71,324 KB
testcase_02 AC 75 ms
71,328 KB
testcase_03 AC 75 ms
71,188 KB
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 AC 75 ms
71,184 KB
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 AC 75 ms
71,196 KB
testcase_12 WA -
testcase_13 WA -
testcase_14 WA -
testcase_15 AC 78 ms
70,968 KB
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 AC 74 ms
71,332 KB
testcase_20 AC 76 ms
71,320 KB
testcase_21 AC 77 ms
71,288 KB
testcase_22 AC 77 ms
71,012 KB
testcase_23 WA -
testcase_24 WA -
testcase_25 AC 77 ms
71,132 KB
testcase_26 AC 76 ms
71,156 KB
testcase_27 AC 75 ms
71,188 KB
testcase_28 AC 76 ms
71,392 KB
testcase_29 AC 77 ms
71,132 KB
testcase_30 AC 77 ms
71,204 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
m = int(input())
if n%m==0:
    n//=m
    while n%10==0: n//=10
    print(n)
    exit()
for i in range(99):
    n *= 10
    if n%m==0:
        print(n%10)
        break
else:
    print(-1)
0