from scipy.special import zeta x=int(input()) if x == 2: print(pow(10,6));exit() MAX = pow(10,2) ans = 0 for n in range(x,MAX): temp = zeta(n)*pow(10,6) - pow(10,6) #temp *= pow(10,6) ans += temp #print(temp) print(ans) ans = int(ans) print(ans)