import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner((System.in));
		String n = sc.next();
		String ans = "Yes";
		int sum = 0;

		for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		}
		
		if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		}
		
		
		System.out.println(ans);

		sc.close();
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner((System.in));
		String n = sc.next();
		String ans = "Yes";
		int sum = 0;

		for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		}
		
		if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		}
		
		
		System.out.println(ans);

		sc.close();
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner((System.in));
		String n = sc.next();
		String ans = "Yes";
		int sum = 0;

		for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		}
		
		if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		}
		
		
		System.out.println(ans);

		sc.close();
	} main {
		Scanner sc = new Scanner((System.in));
		String n = sc.next();
		String ans = "Yes";
		int sum = 0;

		for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		}
		
		if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		}
		
		
		System.out.println(ans);

		sc.close();
	} Scanner sc = new Scanner((System.in)); sc new Scanner((System.in)) String n = sc.next(); n sc.next() sc.next sc String ans = "Yes"; ans "Yes" int sum = 0; sum 0 for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		} int i = 0; int i = 0; i 0 i < n.length() i n.length() n.length n i++ i++ i {
			sum += Integer.valueOf(n.substring(i, i + 1));
		} {
			sum += Integer.valueOf(n.substring(i, i + 1));
		} sum += Integer.valueOf(n.substring(i, i + 1)) sum Integer.valueOf(n.substring(i, i + 1)) Integer.valueOf Integer n.substring(i, i + 1) n.substring n i i + 1 i 1 if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		} Integer.valueOf(n) % sum != 0 Integer.valueOf(n) % sum Integer.valueOf(n) Integer.valueOf Integer n sum 0 {
			ans = "No";
		} ans = "No" ans "No" System.out.println(ans) System.out.println System.out System System.out ans sc.close() sc.close sc String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner((System.in));
		String n = sc.next();
		String ans = "Yes";
		int sum = 0;

		for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		}
		
		if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		}
		
		
		System.out.println(ans);

		sc.close();
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner((System.in));
		String n = sc.next();
		String ans = "Yes";
		int sum = 0;

		for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		}
		
		if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		}
		
		
		System.out.println(ans);

		sc.close();
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner((System.in));
		String n = sc.next();
		String ans = "Yes";
		int sum = 0;

		for (int i = 0; i < n.length(); i++) {
			sum += Integer.valueOf(n.substring(i, i + 1));
		}
		
		if (Integer.valueOf(n) % sum != 0) {
			ans = "No";
		}
		
		
		System.out.println(ans);

		sc.close();
	}
}
