[프로그래머스][Python] 하샤드 수
def solution(arr):
total=0
arr = str(arr)
for i in arr:
total = total + eval(i)
if int(arr) %total ==0:
return True
else :
return False
def solution(arr):
total=0
arr = str(arr)
for i in arr:
total = total + eval(i)
if int(arr) %total ==0:
return True
else :
return False