結果
| 問題 |
No.3072 Speedrun Query
|
| コンテスト | |
| ユーザー |
gew1fw
|
| 提出日時 | 2025-06-12 19:51:15 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 607 bytes |
| コンパイル時間 | 153 ms |
| コンパイル使用メモリ | 82,456 KB |
| 実行使用メモリ | 80,664 KB |
| 最終ジャッジ日時 | 2025-06-12 19:51:20 |
| 合計ジャッジ時間 | 4,499 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 1 |
| other | RE * 21 |
ソースコード
import sys
from decimal import Decimal, getcontext
getcontext().prec = 35 # Set precision high enough to handle up to 1e6 terms with 1e-15 error
def main():
N = int(sys.stdin.readline())
x_list = []
for _ in range(N):
x = int(sys.stdin.readline())
x_list.append(Decimal(x))
prefix_sums = []
current_sum = Decimal(0)
for xi in x_list:
current_sum += xi.sqrt()
prefix_sums.append(current_sum)
# Printing each sum with 17 decimal places
for s in prefix_sums:
print("{0:.17f}".format(s))
if __name__ == "__main__":
main()
gew1fw