fork(1) download
  1. n = int(input())
  2. sum = 0
  3. for i in range (1,n+1,1):
  4. sum = sum + 1/i
  5. print (sum)
Success #stdin #stdout 0.01s 7304KB
stdin
3
stdout
1