import std.stdio;
import std.string;
import std.conv;
import std.algorithm;

int s_n(int n) {
    int sum = 0;
    while (n != 0) {
        sum += n % 10;
        n /= 10;
    }

    return sum;
}

void main() {
    int n = readln.chomp.to!(int);

    writeln((n % s_n(n) == 0) ? "Yes" : "No");
}