import java.util.Scanner
 
fun main(args: Array<String>) {
  val scanner = Scanner(System.`in`)
  val string = scanner.next()
  scanner.close()
  var sum = 0
  for (char in string.toCharArray()) {
    sum += char.toString().toInt()
  }
  print(if(string.toInt() % sum == 0) "Yes" else "No")
}