import java.util.Scanner;

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

        int n = sc.nextInt();
        int v = n;

        int z = v % 10;
        while (v >= 10) {
            v /= 10;
            z += v % 10;
        }

        System.out.print(n % z == 0 ? "Yes" : "No");
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int v = n;

        int z = v % 10;
        while (v >= 10) {
            v /= 10;
            z += v % 10;
        }

        System.out.print(n % z == 0 ? "Yes" : "No");
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int v = n;

        int z = v % 10;
        while (v >= 10) {
            v /= 10;
            z += v % 10;
        }

        System.out.print(n % z == 0 ? "Yes" : "No");
    } main {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int v = n;

        int z = v % 10;
        while (v >= 10) {
            v /= 10;
            z += v % 10;
        }

        System.out.print(n % z == 0 ? "Yes" : "No");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int v = n; v n int z = v % 10; z v % 10 v 10 while (v >= 10) {
            v /= 10;
            z += v % 10;
        } v >= 10 v 10 {
            v /= 10;
            z += v % 10;
        } v /= 10 v 10 z += v % 10 z v % 10 v 10 System.out.print(n % z == 0 ? "Yes" : "No") System.out.print System.out System System.out n % z == 0 ? "Yes" : "No" n % z == 0 n % z n z 0 "Yes" "No" String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int v = n;

        int z = v % 10;
        while (v >= 10) {
            v /= 10;
            z += v % 10;
        }

        System.out.print(n % z == 0 ? "Yes" : "No");
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int v = n;

        int z = v % 10;
        while (v >= 10) {
            v /= 10;
            z += v % 10;
        }

        System.out.print(n % z == 0 ? "Yes" : "No");
    }
} Main
import java.util.Scanner;

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

        int n = sc.nextInt();
        int v = n;

        int z = v % 10;
        while (v >= 10) {
            v /= 10;
            z += v % 10;
        }

        System.out.print(n % z == 0 ? "Yes" : "No");
    }
}
