p = int(input()) ok = 0 i = 1 j = 1 while (i * i <= p): while(j * j <= p): ok |= i*i + j*j == p j+=1 i+=1 print("Yes" if ok else "No")