結果
| 問題 |
No.2971 無理積分
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-11-29 21:39:14 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 71 ms / 1,000 ms |
| コード長 | 198 bytes |
| コンパイル時間 | 217 ms |
| コンパイル使用メモリ | 82,048 KB |
| 実行使用メモリ | 62,208 KB |
| 最終ジャッジ日時 | 2024-11-29 21:39:21 |
| 合計ジャッジ時間 | 4,017 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 36 |
ソースコード
n = int(input())
def f(x):
return (x * x * x + n * n * n) ** 0.5
N = 10 ** 5
a = 0
b = 1
h = (b-a)/N
S = (h/3) * sum((f(h*i) + 4*f(h*(i+1)) + f(h*(i+2))) for i in range(0,N-1, 2))
print(S)