import java.util.*;
public class Main{
public static void main(String[] args)throws Exception{
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
System.out.printf("%.3f",sum(n));
}
public static double sum(int n){
double sum = 0;
double sum_total = 0;
int c = -1;
for(int i = 1; i <= n; i++){
c *= -1;
sum += (2 * i - 1) * c;
sum_total += 1.0 / sum;
}
return sum_total;
}
}