n=int(input()) INF=10**10 dp=[INF for i in range(n+1)] dp[1]=1 def popcount(x): return bin(x).count("1") que=[1] head=0 while head