#9命,调了好久终于把运行时间调到规定内了🤣
def nk(count,n,m): if sum(count) == n and len(count) == m: print(str(count).replace("[","").replace(",", "+").replace("]","").replace(" ","")) return True while True: try: m = int(input()) n = m * m * m #n是m的立方 count = [] flag = 0 i = 0 while flag ==0: for j in range(i,i+2*m+1,2):#遍历j往后的m个奇数,若总和为n则输出 count.append(j) if (nk(count,n,m)): flag = 1 i += 1 count = [] except: break