結果
| 問題 |
No.1271 初めての級数
|
| コンテスト | |
| ユーザー |
c-yan
|
| 提出日時 | 2020-10-30 22:19:43 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 218 bytes |
| コンパイル時間 | 134 ms |
| コンパイル使用メモリ | 12,800 KB |
| 実行使用メモリ | 14,848 KB |
| 最終ジャッジ日時 | 2024-07-22 01:10:08 |
| 合計ジャッジ時間 | 4,280 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | WA * 13 |
ソースコード
from heapq import heappop, heappush
k = int(input())
t = []
for n in range(1, 100000):
heappush(t, 1 / (n * (n + k)))
while len(t) != 1:
a = heappop(t)
b = heappop(t)
heappush(t, a + b)
print(t[0])
c-yan