N = input()
if N == '0':
    print('yes')
else:
    if N[0] == '-':
        N = int(N) * (-1)
    sum = 0
    for i in N:
        sum = sum + int(i)
    r = int(N) % sum
    if r == 0:
        print('yes')
    else:
        print('no')
