import math S=int(input()) ans=[] for i in range(15): ans.append(math.floor(math.sqrt(S))**2) S-=ans[-1] if S==0: break print(len(ans)) print(*ans)