import java.util.*;
import java.io.*;
public class Main {
    public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		PrintWriter ou = new PrintWriter(System.out);
		int n = Integer.parseInt(sc.next());
		int nn = n;
		int s = 0;
		while(nn != 0){
			s += nn % 10;
			nn /= 10;
		}
		if(n % s == 0) ou.println("Yes");
		else ou.println("No");
		ou.flush();
	}
} import java.util.*; util.* java import java.io.*; io.* java public class Main {
    public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		PrintWriter ou = new PrintWriter(System.out);
		int n = Integer.parseInt(sc.next());
		int nn = n;
		int s = 0;
		while(nn != 0){
			s += nn % 10;
			nn /= 10;
		}
		if(n % s == 0) ou.println("Yes");
		else ou.println("No");
		ou.flush();
	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		PrintWriter ou = new PrintWriter(System.out);
		int n = Integer.parseInt(sc.next());
		int nn = n;
		int s = 0;
		while(nn != 0){
			s += nn % 10;
			nn /= 10;
		}
		if(n % s == 0) ou.println("Yes");
		else ou.println("No");
		ou.flush();
	} main {
		Scanner sc = new Scanner(System.in);
		PrintWriter ou = new PrintWriter(System.out);
		int n = Integer.parseInt(sc.next());
		int nn = n;
		int s = 0;
		while(nn != 0){
			s += nn % 10;
			nn /= 10;
		}
		if(n % s == 0) ou.println("Yes");
		else ou.println("No");
		ou.flush();
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) PrintWriter ou = new PrintWriter(System.out); ou new PrintWriter(System.out) int n = Integer.parseInt(sc.next()); n Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int nn = n; nn n int s = 0; s 0 while(nn != 0){
			s += nn % 10;
			nn /= 10;
		} nn != 0 nn 0 {
			s += nn % 10;
			nn /= 10;
		} s += nn % 10 s nn % 10 nn 10 nn /= 10 nn 10 if(n % s == 0) ou.println("Yes");
		else ou.println("No"); n % s == 0 n % s n s 0 ou.println("Yes") ou.println ou "Yes" ou.println("No") ou.println ou "No" ou.flush() ou.flush ou String[] args args public class Main {
    public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		PrintWriter ou = new PrintWriter(System.out);
		int n = Integer.parseInt(sc.next());
		int nn = n;
		int s = 0;
		while(nn != 0){
			s += nn % 10;
			nn /= 10;
		}
		if(n % s == 0) ou.println("Yes");
		else ou.println("No");
		ou.flush();
	}
} public class Main {
    public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		PrintWriter ou = new PrintWriter(System.out);
		int n = Integer.parseInt(sc.next());
		int nn = n;
		int s = 0;
		while(nn != 0){
			s += nn % 10;
			nn /= 10;
		}
		if(n % s == 0) ou.println("Yes");
		else ou.println("No");
		ou.flush();
	}
} Main
import java.util.*;
import java.io.*;
public class Main {
    public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		PrintWriter ou = new PrintWriter(System.out);
		int n = Integer.parseInt(sc.next());
		int nn = n;
		int s = 0;
		while(nn != 0){
			s += nn % 10;
			nn /= 10;
		}
		if(n % s == 0) ou.println("Yes");
		else ou.println("No");
		ou.flush();
	}
}