program main
  implicit none
  integer(8) :: n, i, k, fn, d
  character(10) :: s
  read(*, *) n
  write(s, "(i0)") n
  k = len(trim(s))
  fn = 0
  do i = 1, k
    read(s(i:i), "(i1)") d
    fn = fn + d
  end do
  if (mod(n, fn) == 0) then
    write(*, "(a)") "Yes"
  else
    write(*, "(a)") "No"
  end if
end program main
