import java.util.Scanner;
public class Main {
  public static void main(String[] args) {
    Scanner scanner = new Scanner(System.in);
    String N = scanner.next();
    int SN = 0;
    for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    }
    if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    }
  }
} import java.util.Scanner; Scanner java.util public class Main {
  public static void main(String[] args) {
    Scanner scanner = new Scanner(System.in);
    String N = scanner.next();
    int SN = 0;
    for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    }
    if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    }
  }
} Main public static void main(String[] args) {
    Scanner scanner = new Scanner(System.in);
    String N = scanner.next();
    int SN = 0;
    for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    }
    if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    }
  } main {
    Scanner scanner = new Scanner(System.in);
    String N = scanner.next();
    int SN = 0;
    for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    }
    if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    }
  } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) String N = scanner.next(); N scanner.next() scanner.next scanner int SN = 0; SN 0 for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    } int i = 0; int i = 0; i 0 i < N.length() i N.length() N.length N i++ i++ i {
      SN += Character.getNumericValue(N.charAt(i));
    } {
      SN += Character.getNumericValue(N.charAt(i));
    } SN += Character.getNumericValue(N.charAt(i)) SN Character.getNumericValue(N.charAt(i)) Character.getNumericValue Character N.charAt(i) N.charAt N i if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    } Integer.parseInt(N) % SN == 0 Integer.parseInt(N) % SN Integer.parseInt(N) Integer.parseInt Integer N SN 0 {
      System.out.println("Yes");
    } System.out.println("Yes") System.out.println System.out System System.out "Yes" {
      System.out.println("No");
    } System.out.println("No") System.out.println System.out System System.out "No" String[] args args public class Main {
  public static void main(String[] args) {
    Scanner scanner = new Scanner(System.in);
    String N = scanner.next();
    int SN = 0;
    for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    }
    if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    }
  }
} public class Main {
  public static void main(String[] args) {
    Scanner scanner = new Scanner(System.in);
    String N = scanner.next();
    int SN = 0;
    for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    }
    if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    }
  }
} Main
import java.util.Scanner;
public class Main {
  public static void main(String[] args) {
    Scanner scanner = new Scanner(System.in);
    String N = scanner.next();
    int SN = 0;
    for (int i = 0; i < N.length(); i++) {
      SN += Character.getNumericValue(N.charAt(i));
    }
    if (Integer.parseInt(N) % SN == 0) {
      System.out.println("Yes");
    } else {
      System.out.println("No");
    }
  }
}
