N=eval(input()) for a in range(1,N+1): for b in range(2,a): for c in range(b,a): for d in range(c,a): if(pow(a,3)==pow(b,3)+pow(c,3)+pow(d,3)): print("Cube = %d,Tripe = (%d,%d,%d)" %(a,b,c,d))