3 lines
45 B
Ruby
3 lines
45 B
Ruby
|
|
n = 1e6
|
||
|
|
p (1..n).sum{ 1.0/_1 } - Math.log(n)
|