#include <bits/stdc++.h>
using namespace std;
int main() {
  long int N, s, f;
  s = 0;
  cin >> N;
  f = N;
  for (int i = 0; i < 1; i--) {
    if (N >= 10) {
      s += N % 10;
      N = (N - N % 10) / 10;
    } else {
      if (f % (s + N) == 0)
        cout << "Yes" << endl;
      else
        cout << "No" << endl;
      return 0;
    }
  }
}
