結果
問題 | No.1993 Horse Racing |
ユーザー |
![]() |
提出日時 | 2022-03-20 19:26:57 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 42 ms / 2,000 ms |
コード長 | 344 bytes |
コンパイル時間 | 149 ms |
コンパイル使用メモリ | 82,196 KB |
実行使用メモリ | 52,480 KB |
最終ジャッジ日時 | 2024-10-09 05:41:55 |
合計ジャッジ時間 | 1,990 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 23 |
ソースコード
n = int(input())assert 2 <= n <= 100a = list(map(int, input().split()))assert n - 1 == len(a)x = 1000y = 1for i in a:assert 0 <= i <= 10x *= 1000 - iy *= 1000while x % 10 == 0 and y % 10 == 0:x //= 10y //= 10x = 1000 * y - xxx = str(x)m = len(str(x)) - len(str(y)) + 1print(xx[:m] + "." + xx[m:])