import java.io.PrintWriter; import java.util.Arrays; import java.util.Scanner; import java.util.Stack; class Main { public static void main(String[] $) { new Main().run(); } void run() { Scanner sc=new Scanner(System.in); int N=sc.nextInt(); double ans=0; for (double i=1;i<1e5;++i) { ans+=Math.pow(1/i, N); } System.out.println(ans); } void tr(Object...objects) {System.out.println(Arrays.deepToString(objects));} }