class Main {
	public static void main(String[] args){
		String N = new java.util.Scanner(System.in).nextLine();
		String[] Narray = N.split("");
		int Nnum = Integer.parseInt(N);
		int Sn = 0;
		for (int i = 0; i < Narray.length; i++) {
			Sn += Integer.parseInt(Narray[i]);
		}
		if (Nnum % Sn == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}
	}
} class Main {
	public static void main(String[] args){
		String N = new java.util.Scanner(System.in).nextLine();
		String[] Narray = N.split("");
		int Nnum = Integer.parseInt(N);
		int Sn = 0;
		for (int i = 0; i < Narray.length; i++) {
			Sn += Integer.parseInt(Narray[i]);
		}
		if (Nnum % Sn == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}
	}
} Main public static void main(String[] args){
		String N = new java.util.Scanner(System.in).nextLine();
		String[] Narray = N.split("");
		int Nnum = Integer.parseInt(N);
		int Sn = 0;
		for (int i = 0; i < Narray.length; i++) {
			Sn += Integer.parseInt(Narray[i]);
		}
		if (Nnum % Sn == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}
	} main {
		String N = new java.util.Scanner(System.in).nextLine();
		String[] Narray = N.split("");
		int Nnum = Integer.parseInt(N);
		int Sn = 0;
		for (int i = 0; i < Narray.length; i++) {
			Sn += Integer.parseInt(Narray[i]);
		}
		if (Nnum % Sn == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}
	} String N = new java.util.Scanner(System.in).nextLine(); N new java.util.Scanner(System.in).nextLine() new java.util.Scanner(System.in).nextLine new java.util.Scanner(System.in) String[] Narray = N.split(""); Narray N.split("") N.split N "" int Nnum = Integer.parseInt(N); Nnum Integer.parseInt(N) Integer.parseInt Integer N int Sn = 0; Sn 0 for (int i = 0; i < Narray.length; i++) {
			Sn += Integer.parseInt(Narray[i]);
		} int i = 0; int i = 0; i 0 i < Narray.length i Narray.length Narray Narray.length i++ i++ i {
			Sn += Integer.parseInt(Narray[i]);
		} {
			Sn += Integer.parseInt(Narray[i]);
		} Sn += Integer.parseInt(Narray[i]) Sn Integer.parseInt(Narray[i]) Integer.parseInt Integer Narray[i] Narray i if (Nnum % Sn == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		} Nnum % Sn == 0 Nnum % Sn Nnum 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
class Main {
	public static void main(String[] args){
		String N = new java.util.Scanner(System.in).nextLine();
		String[] Narray = N.split("");
		int Nnum = Integer.parseInt(N);
		int Sn = 0;
		for (int i = 0; i < Narray.length; i++) {
			Sn += Integer.parseInt(Narray[i]);
		}
		if (Nnum % Sn == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}
	}
}