結果

問題 No.81 すべて足すだけの簡単なお仕事です。
コンテスト
ユーザー rin204
提出日時 2022-07-04 14:08:39
言語 PyPy3
(7.3.23 + ACL)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
AC  
実行時間 57 ms / 5,000 ms
+ 263µs
コード長 355 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 263 ms
コンパイル使用メモリ 95,852 KB
実行使用メモリ 79,064 KB
最終ジャッジ日時 2026-08-23 10:36:35
合計ジャッジ時間 3,753 ms
ジャッジサーバーID
(参考情報)
judge1_0 / judge3_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 30
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

n = int(input())
tot = 0
for _ in range(n):
    S = input()
    try:
        ind = S.index(".")
    except:
        ind = len(S)
    S = S[:ind] + S[ind+1:].ljust(10, "0")
    tot += int(S)
tot = str(tot)
minus = False
if tot[0] == "-":
    minus = True
    tot = tot[1:]
tot = tot.zfill(11)
if minus:
    tot = "-" + tot
print(f"{tot[:-10]}.{tot[-10:]}")
0