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

void main() {
    auto N = readln.chomp.to!long;
    auto n = N;
    auto S = 0;
    while (n > 0) {
        S += n % 10;
        n /= 10;
    }
    writeln(N % S == 0 ? "Yes" : "No");
}

