n,z=map(int,input().split()) r=int(z**.5)+2 z2=z**2 for x in range(1,r): y=((z-x)*(z+x))**.5 if y.is_integer():print("Yes");break else: print("No")