fork download
  1. using C=System.Console;
  2. class S{static void Main(){for(double n=int.Parse(C.ReadLine()),r,t;n-->0;C.WriteLine(r))for(r=0,t=2*int.Parse(C.ReadLine());t>0;t--)r-=(1-t%4)/--t;}}
Success #stdin #stdout 0.04s 24256KB
stdin
4
1
2
3
100000
stdout
1
0.666666666666667
0.866666666666667
0.785395663397448