'use strict'

const main = input => {
	const n = parseInt(input.split('\n')[0], 10)
	let t1 = n 
	let sum = 0

	while (t1 > 0) {
		sum += t1 % 10
		t1 = Math.floor(t1 / 10)
	}

	if (n % sum === 0) console.log('Yes')
	else console.log('No')
}

main(require('fs').readFileSync('/dev/stdin', 'utf8'))
