p = int(input()) s = {i*i for i in range(1,2*10**4)} for i in range(1,2*10**4): if p-i*i in s: print("Yes") exit() print("No")