import java.util.*;

public class Main {
    fun main(args: Array<String>) {
        val scan = Scanner(System.`in`)
        val inputStr = scan.nextLine()
        val num1 = Integer.parseInt(inputStr)
        val charArray = inputStr.toCharArray()
        val num2 = 0
        for (i in charArray) {
            num2 = num2 + Character.getNumericValue(i)
        }
        if ((num1 % num2) == 0) {
		System.out.print("Yes");
	} else {
		System.out.print("No");
	}
    }
}