P=int(input()) r=2 while r*r*2<=P: r+=1 for i in range(r): i2=i*i for j in range(i,r): if P==i2+j*j: print("Yes") exit(0) print("No")