No.1271 初めての級数
問題文最終更新日: 2021-05-08 01:05:07
English (AI translation)
My First Series
This statement was translated by AI (claude-opus-5-5, effort medium) and may contain errors or differ in nuance from the original. The original statement takes precedence. Show the original
This statement was translated by AI (claude-opus-5-5, effort medium) and may contain errors or differ in nuance from the original. The original statement takes precedence. Show the original
Problem Statement
Kamitori-san was given the following problem at school.
$ \displaystyle \sum_{n=1}^{\infty} \frac{1}{n(n+k)}$を求めてください。
However, Kamitori-san cannot solve this problem. Please solve it in place of Kamitori-san.It is guaranteed that this series converges within the specified range.
Input
$k$
Output
Print a newline at the end. Also, make sure that at least one of the absolute error and the relative error is at most $10^{-6}$.
[Added at 21:24] Output the value of this infinite series.Sample
Sample 1
Input
1
Output
1
Sample 2
Input
2
Output
0.75
Sample 3
Input
100
Output
0.0518737751763962
提出するには、Twitter 、GitHub、 Googleもしくは右上の雲マークをクリックしてアカウントを作成してください。
57tggx