import java.util.*;
public class Main{
  
 public static void main(String[] args){
  Scanner scanner = new Scanner(System.in);
   String input = scanner.nextLine();
   int sum = 0;
   for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   }
   if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   }
 }
  
} import java.util.*; util.* java public class Main{
  
 public static void main(String[] args){
  Scanner scanner = new Scanner(System.in);
   String input = scanner.nextLine();
   int sum = 0;
   for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   }
   if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   }
 }
  
} Main public static void main(String[] args){
  Scanner scanner = new Scanner(System.in);
   String input = scanner.nextLine();
   int sum = 0;
   for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   }
   if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   }
 } main {
  Scanner scanner = new Scanner(System.in);
   String input = scanner.nextLine();
   int sum = 0;
   for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   }
   if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   }
 } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) String input = scanner.nextLine(); input scanner.nextLine() scanner.nextLine scanner int sum = 0; sum 0 for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   } int x =0; int x =0; x 0 x<input.length() x input.length() input.length input x++ x++ x {
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   } {
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   } sum = sum + Integer.parseInt(input.substring(x,x+1)) sum sum + Integer.parseInt(input.substring(x,x+1)) sum Integer.parseInt(input.substring(x,x+1)) Integer.parseInt Integer input.substring(x,x+1) input.substring input x x+1 x 1 if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   } Integer.parseInt(input)%sum==0 Integer.parseInt(input)%sum Integer.parseInt(input) Integer.parseInt Integer input sum 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 scanner = new Scanner(System.in);
   String input = scanner.nextLine();
   int sum = 0;
   for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   }
   if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   }
 }
  
} public class Main{
  
 public static void main(String[] args){
  Scanner scanner = new Scanner(System.in);
   String input = scanner.nextLine();
   int sum = 0;
   for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   }
   if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   }
 }
  
} Main
import java.util.*;
public class Main{
  
 public static void main(String[] args){
  Scanner scanner = new Scanner(System.in);
   String input = scanner.nextLine();
   int sum = 0;
   for(int x =0; x<input.length(); x++){
     sum = sum + Integer.parseInt(input.substring(x,x+1));
   }
   if(Integer.parseInt(input)%sum==0){
     System.out.println("Yes");
   }else{
     System.out.println("No");
   }
 }
  
}