import java.util.*; public class Main { public static void main (String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); double ans = 0; for (int i = 1; i <= 1000000; i++) { ans += 1 / Math.pow(i, n); } System.out.println(ans); } }