import java.util.*;
class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);

        String n = sc.next();
        int N = Integer.parseInt(n);
        char[] num = new char[n.length()];
        int[] Num = new int[n.length()];
        int ans = 0;
        for(int i = 0;i < n.length();i++){
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        }
        for(int i = 0;i < n.length();i++){
            ans += Num[i];
        }
        if(N % ans == 0){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
} import java.util.*; util.* java class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);

        String n = sc.next();
        int N = Integer.parseInt(n);
        char[] num = new char[n.length()];
        int[] Num = new int[n.length()];
        int ans = 0;
        for(int i = 0;i < n.length();i++){
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        }
        for(int i = 0;i < n.length();i++){
            ans += Num[i];
        }
        if(N % ans == 0){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
} Main public static void main(String[] args){
        Scanner sc = new Scanner(System.in);

        String n = sc.next();
        int N = Integer.parseInt(n);
        char[] num = new char[n.length()];
        int[] Num = new int[n.length()];
        int ans = 0;
        for(int i = 0;i < n.length();i++){
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        }
        for(int i = 0;i < n.length();i++){
            ans += Num[i];
        }
        if(N % ans == 0){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    } main {
        Scanner sc = new Scanner(System.in);

        String n = sc.next();
        int N = Integer.parseInt(n);
        char[] num = new char[n.length()];
        int[] Num = new int[n.length()];
        int ans = 0;
        for(int i = 0;i < n.length();i++){
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        }
        for(int i = 0;i < n.length();i++){
            ans += Num[i];
        }
        if(N % ans == 0){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String n = sc.next(); n sc.next() sc.next sc int N = Integer.parseInt(n); N Integer.parseInt(n) Integer.parseInt Integer n char[] num = new char[n.length()]; num new char[n.length()] n.length() n.length n int[] Num = new int[n.length()]; Num new int[n.length()] n.length() n.length n int ans = 0; ans 0 for(int i = 0;i < n.length();i++){
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        } int i = 0; int i = 0; i 0 i < n.length() i n.length() n.length n i++ i++ i {
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        } {
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        } num[i] = n.charAt(i) num[i] num i n.charAt(i) n.charAt n i Num[i] = Character.getNumericValue(num[i]) Num[i] Num i Character.getNumericValue(num[i]) Character.getNumericValue Character num[i] num i for(int i = 0;i < n.length();i++){
            ans += Num[i];
        } int i = 0; int i = 0; i 0 i < n.length() i n.length() n.length n i++ i++ i {
            ans += Num[i];
        } {
            ans += Num[i];
        } ans += Num[i] ans Num[i] Num i if(N % ans == 0){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        } N % ans == 0 N % ans N ans 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
import java.util.*;
class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);

        String n = sc.next();
        int N = Integer.parseInt(n);
        char[] num = new char[n.length()];
        int[] Num = new int[n.length()];
        int ans = 0;
        for(int i = 0;i < n.length();i++){
            num[i] = n.charAt(i);
            Num[i] = Character.getNumericValue(num[i]);
        }
        for(int i = 0;i < n.length();i++){
            ans += Num[i];
        }
        if(N % ans == 0){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
}