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