object Main{
  def main(args: Array[String]){
    val input=io.Source.stdin.getLines().mkString("\n")
    println(solve(input).trim())
  }

  def solve(input:String):String={
    val n=input.toInt
    val k=input.toList.foldLeft(0){(acc,x)=>acc+x-'0'}
    if(n%k==0){
      "Yes"
    }else{
      "No"
    }
  }
}
