a, b=list(map(int, input().split()))

N=int(str(a)+str(b))

for i in range(1, 10000):

  if N//i==i and N%i==0:

    print('Yes')

    exit()

print('No')
a, b=list(map(int, input().split()))

N=int(str(a)+str(b))

if pow(N, 1/2)%1==0:

  print('Yes')

else:

  print('No')
a, b = list(map(int, input().split()))
N = int(str(a) + str(b))
for i in range(1, 10000):
    if N // i == i and N % i == 0:
        print("Yes")
        exit()
print("No")

a, b = list(map(int, input().split()))
N = int(str(a) + str(b))
if pow(N, 1 / 2) % 1 == 0:
    print("Yes")
else:
    print("No")

-for i in range(1, 10000): -    if N // i == i and N % i == 0: -        print("Yes") -        exit() -print("No") +if pow(N, 1 / 2) % 1 == 0: +    print("Yes") +else: +    print("No")