import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		int n = in.nextInt();
		System.out.println(solve(n));
		in.close();
	}

	private static String solve(int n) {
		int s = 0;
		int w = n;
		while (w > 0) {
			s += (w % 10);
			w /= 10;
		}
		if (n % s == 0)
			return "Yes";
		else
			return "No";
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		int n = in.nextInt();
		System.out.println(solve(n));
		in.close();
	}

	private static String solve(int n) {
		int s = 0;
		int w = n;
		while (w > 0) {
			s += (w % 10);
			w /= 10;
		}
		if (n % s == 0)
			return "Yes";
		else
			return "No";
	}
} Main public static void main(String[] args) {
		Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		int n = in.nextInt();
		System.out.println(solve(n));
		in.close();
	} main {
		Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		int n = in.nextInt();
		System.out.println(solve(n));
		in.close();
	} Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in))); in new Scanner(new BufferedReader(new InputStreamReader(System.in))) int n = in.nextInt(); n in.nextInt() in.nextInt in System.out.println(solve(n)) System.out.println System.out System System.out solve(n) solve n in.close() in.close in String[] args args private static String solve(int n) {
		int s = 0;
		int w = n;
		while (w > 0) {
			s += (w % 10);
			w /= 10;
		}
		if (n % s == 0)
			return "Yes";
		else
			return "No";
	} solve {
		int s = 0;
		int w = n;
		while (w > 0) {
			s += (w % 10);
			w /= 10;
		}
		if (n % s == 0)
			return "Yes";
		else
			return "No";
	} int s = 0; s 0 int w = n; w n while (w > 0) {
			s += (w % 10);
			w /= 10;
		} w > 0 w 0 {
			s += (w % 10);
			w /= 10;
		} s += (w % 10) s (w % 10) w 10 w /= 10 w 10 if (n % s == 0)
			return "Yes";
		else
			return "No"; n % s == 0 n % s n s 0 return "Yes"; "Yes" return "No"; "No" int n n public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		int n = in.nextInt();
		System.out.println(solve(n));
		in.close();
	}

	private static String solve(int n) {
		int s = 0;
		int w = n;
		while (w > 0) {
			s += (w % 10);
			w /= 10;
		}
		if (n % s == 0)
			return "Yes";
		else
			return "No";
	}
} public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		int n = in.nextInt();
		System.out.println(solve(n));
		in.close();
	}

	private static String solve(int n) {
		int s = 0;
		int w = n;
		while (w > 0) {
			s += (w % 10);
			w /= 10;
		}
		if (n % s == 0)
			return "Yes";
		else
			return "No";
	}
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner in = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
		int n = in.nextInt();
		System.out.println(solve(n));
		in.close();
	}

	private static String solve(int n) {
		int s = 0;
		int w = n;
		while (w > 0) {
			s += (w % 10);
			w /= 10;
		}
		if (n % s == 0)
			return "Yes";
		else
			return "No";
	}
}