import std.stdio, std.algorithm, std.string, std.conv, std.array, std.range, std.math;
int read() { return readln.chomp.to!int; }
int[] reads() { return readln.split.to!(int[]); }

int s(string n) {
    int z;
    foreach (c; n) z += c - '0';
    return z;
}

void solve() {
    string n = readln.chomp;
    debug {
        writeln(n, s(n));
    }
    writeln(n.to!int % s(n) == 0 ? "Yes" : "No");
}

void main() {
    solve();
    readln;
}