import java.util.Scanner;
 
public class Main {
 
	public static void main(String[] args) {
 
		Scanner scan = new Scanner(System.in);
 
		int N = scan.nextInt();

		int count = 0;
		int M = N;

		while(M != 0){
			count += M%10;
			M = M/10;
		}
		
		if(N % count == 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 scan = new Scanner(System.in);
 
		int N = scan.nextInt();

		int count = 0;
		int M = N;

		while(M != 0){
			count += M%10;
			M = M/10;
		}
		
		if(N % count == 0){
			System.out.println("Yes");	
		}else{
			System.out.println("No");
		}


	}
 
} Main public static void main(String[] args) {
 
		Scanner scan = new Scanner(System.in);
 
		int N = scan.nextInt();

		int count = 0;
		int M = N;

		while(M != 0){
			count += M%10;
			M = M/10;
		}
		
		if(N % count == 0){
			System.out.println("Yes");	
		}else{
			System.out.println("No");
		}


	} main {
 
		Scanner scan = new Scanner(System.in);
 
		int N = scan.nextInt();

		int count = 0;
		int M = N;

		while(M != 0){
			count += M%10;
			M = M/10;
		}
		
		if(N % count == 0){
			System.out.println("Yes");	
		}else{
			System.out.println("No");
		}


	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int N = scan.nextInt(); N scan.nextInt() scan.nextInt scan int count = 0; count 0 int M = N; M N while(M != 0){
			count += M%10;
			M = M/10;
		} M != 0 M 0 {
			count += M%10;
			M = M/10;
		} count += M%10 count M%10 M 10 M = M/10 M M/10 M 10 if(N % count == 0){
			System.out.println("Yes");	
		}else{
			System.out.println("No");
		} N % count == 0 N % count N count 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 scan = new Scanner(System.in);
 
		int N = scan.nextInt();

		int count = 0;
		int M = N;

		while(M != 0){
			count += M%10;
			M = M/10;
		}
		
		if(N % count == 0){
			System.out.println("Yes");	
		}else{
			System.out.println("No");
		}


	}
 
} public class Main {
 
	public static void main(String[] args) {
 
		Scanner scan = new Scanner(System.in);
 
		int N = scan.nextInt();

		int count = 0;
		int M = N;

		while(M != 0){
			count += M%10;
			M = M/10;
		}
		
		if(N % count == 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 scan = new Scanner(System.in);
 
		int N = scan.nextInt();

		int count = 0;
		int M = N;

		while(M != 0){
			count += M%10;
			M = M/10;
		}
		
		if(N % count == 0){
			System.out.println("Yes");	
		}else{
			System.out.println("No");
		}


	}
 
}