'''import time
start = time.time()'''
from math import sqrt
n = int(input().strip())
count = 0

for i in range(1, int(sqrt(n))+1):
    if n%i == 0:
        count += i
        count += n//i
if count == 2:
    temp = count
else:
    temp = count - n
if temp == n:
    print('yes')
else:
    print('no')
'''end = time.time()
print(end-start)'''

c185dbf3dfe92d80bc26c9b3b3ab522c6378962a
<mask token>

<mask token>
for i in range(1, int(sqrt(n)) + 1):
    if n % i == 0:
        count += i
        count += n // i
if count == 2:
    temp = count
else:
    temp = count - n
if temp == n:
    print('yes')
else:
    print('no')
<mask token>

<mask token>
n = int(input().strip())
count = 0
for i in range(1, int(sqrt(n)) + 1):
    if n % i == 0:
        count += i
        count += n // i
if count == 2:
    temp = count
else:
    temp = count - n
if temp == n:
    print('yes')
else:
    print('no')
<mask token>

<mask token>
from math import sqrt
n = int(input().strip())
count = 0
for i in range(1, int(sqrt(n)) + 1):
    if n % i == 0:
        count += i
        count += n // i
if count == 2:
    temp = count
else:
    temp = count - n
if temp == n:
    print('yes')
else:
    print('no')
<mask token>

'''import time
start = time.time()'''
from math import sqrt
n = int(input().strip())
count = 0

for i in range(1, int(sqrt(n))+1):
    if n%i == 0:
        count += i
        count += n//i
if count == 2:
    temp = count
else:
    temp = count - n
if temp == n:
    print('yes')
else:
    print('no')
'''end = time.time()
print(end-start)'''
