import java.util.Scanner;

class Main{
	
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int div = 0;
		for (char c : S.toCharArray()) {
			div += Character.getNumericValue(c);
		}
		
		System.out.println(Integer.parseInt(S) % div == 0 ? "Yes": "No");
	}
	
} import java.util.Scanner; Scanner java.util class Main{
	
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int div = 0;
		for (char c : S.toCharArray()) {
			div += Character.getNumericValue(c);
		}
		
		System.out.println(Integer.parseInt(S) % div == 0 ? "Yes": "No");
	}
	
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int div = 0;
		for (char c : S.toCharArray()) {
			div += Character.getNumericValue(c);
		}
		
		System.out.println(Integer.parseInt(S) % div == 0 ? "Yes": "No");
	} main {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int div = 0;
		for (char c : S.toCharArray()) {
			div += Character.getNumericValue(c);
		}
		
		System.out.println(Integer.parseInt(S) % div == 0 ? "Yes": "No");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String S = sc.next(); S sc.next() sc.next sc int div = 0; div 0 for (char c : S.toCharArray()) {
			div += Character.getNumericValue(c);
		} char c S.toCharArray() S.toCharArray S {
			div += Character.getNumericValue(c);
		} {
			div += Character.getNumericValue(c);
		} div += Character.getNumericValue(c) div Character.getNumericValue(c) Character.getNumericValue Character c System.out.println(Integer.parseInt(S) % div == 0 ? "Yes": "No") System.out.println System.out System System.out Integer.parseInt(S) % div == 0 ? "Yes": "No" Integer.parseInt(S) % div == 0 Integer.parseInt(S) % div Integer.parseInt(S) Integer.parseInt Integer S div 0 "Yes" "No" String[] args args
import java.util.Scanner;

class Main{
	
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int div = 0;
		for (char c : S.toCharArray()) {
			div += Character.getNumericValue(c);
		}
		
		System.out.println(Integer.parseInt(S) % div == 0 ? "Yes": "No");
	}
	
}