n=int(input()) ANS=[] SUM=0 now=1 for i in range(1,10**6+5): while SUM