結果
問題 | No.25 有限小数 |
ユーザー |
![]() |
提出日時 | 2024-12-23 23:57:38 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 255 bytes |
コンパイル時間 | 146 ms |
コンパイル使用メモリ | 82,268 KB |
実行使用メモリ | 54,352 KB |
最終ジャッジ日時 | 2024-12-23 23:57:42 |
合計ジャッジ時間 | 2,185 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 17 WA * 14 |
ソースコード
N = int(input()) M = int(input()) X2 = 0 M2 = M while M2 % 2 == 0: M2 //= 2 while M2 % 5 == 0: M2 //= 5 if M2 != 1: print(-1) exit() S = str(N*10**18/M) for s in reversed(S): if s != "0" and s != ".": print(s) exit()