import std.algorithm;
import std.array;
import std.conv;
import std.math;
import std.range;
import std.stdio;
import std.string;
import std.typecons;

T read(T)() { return readln.chomp.to!T; }
T[] reads(T)() { return readln.split.to!(T[]); }
alias readint = read!int;
alias readints = reads!int;

int[] digits(int n) {
    if (n == 0) return [0];

    int[] d;
    while (n > 0) {
        d ~= n % 10;
        n /= 10;
    }
    d.reverse();
    return d;
}

void main() {
    int n = readint;
    writeln(n % digits(n).sum == 0 ? "Yes" : "No");
}
