local flo = math.floor

local function div_flo(divided, dividing)
	return flo(divided / dividing)
end

local N = io.read("*n")

local sum = 0
local num = N
while true do
	if num <= 0 then
		break
	end
	local drow = div_flo(num, 10) * 10
	sum = sum + num - drow

	num = div_flo(num, 10)
end

print((N % sum == 0) and "Yes" or "No")