import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String s = sc.nextLine();
int n=Integer.parseInt(s);
char c[]=s.toCharArray();
int fn=0;
for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
}

if(n%fn==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 s = sc.nextLine();
int n=Integer.parseInt(s);
char c[]=s.toCharArray();
int fn=0;
for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
}

if(n%fn==0){
	System.out.println("Yes");
}else{
	System.out.println("No");
}
	}} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String s = sc.nextLine();
int n=Integer.parseInt(s);
char c[]=s.toCharArray();
int fn=0;
for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
}

if(n%fn==0){
	System.out.println("Yes");
}else{
	System.out.println("No");
}
	} main {
		Scanner sc = new Scanner(System.in);
		String s = sc.nextLine();
int n=Integer.parseInt(s);
char c[]=s.toCharArray();
int fn=0;
for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
}

if(n%fn==0){
	System.out.println("Yes");
}else{
	System.out.println("No");
}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String s = sc.nextLine(); s sc.nextLine() sc.nextLine sc int n=Integer.parseInt(s); n Integer.parseInt(s) Integer.parseInt Integer s char c[]=s.toCharArray(); c s.toCharArray() s.toCharArray s int fn=0; fn 0 for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
} int i=0; int i=0; i 0 i<c.length i c.length c c.length i++ i++ i {
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
} {
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
} String k=String.valueOf(c[i]); k String.valueOf(c[i]) String.valueOf String c[i] c i fn+=Integer.parseInt(k) fn Integer.parseInt(k) Integer.parseInt Integer k if(n%fn==0){
	System.out.println("Yes");
}else{
	System.out.println("No");
} n%fn==0 n%fn n fn 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 s = sc.nextLine();
int n=Integer.parseInt(s);
char c[]=s.toCharArray();
int fn=0;
for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
}

if(n%fn==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 s = sc.nextLine();
int n=Integer.parseInt(s);
char c[]=s.toCharArray();
int fn=0;
for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
}

if(n%fn==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 s = sc.nextLine();
int n=Integer.parseInt(s);
char c[]=s.toCharArray();
int fn=0;
for(int i=0;i<c.length;i++){
	String k=String.valueOf(c[i]);
	fn+=Integer.parseInt(k);
}

if(n%fn==0){
	System.out.println("Yes");
}else{
	System.out.println("No");
}
	}}