from math import sqrt S=int(input()) rest=S for i in range(15): m=int(rest**0.5) rest-=int(rest**0.5)**2 print(m**2,end=" ") if rest==0: break print()