a,b = input().split()

c = int(a+b)

print(('Yes' if c**0.5 == int(c**0.5) else 'No'))
a, b = input().split()

c = int(a + b)



for i in range(1,1001):

  if i * i == c:

    print("Yes")

    break

else:

  print("No")

a, b = input().split()
c = int(a + b)
print(("Yes" if c**0.5 == int(c**0.5) else "No"))

a, b = input().split()
c = int(a + b)
for i in range(1, 1001):
    if i * i == c:
        print("Yes")
        break
else:
    print("No")

-print(("Yes" if c**0.5 == int(c**0.5) else "No")) +for i in range(1, 1001): +    if i * i == c: +        print("Yes") +        break +else: +    print("No")