S = int(input()) A = [] while S > 0: k = int(pow(S,0.5)//1) A.append(pow(k,2)) S -= pow(k,2) print(*A)