Skip to content

Instantly share code, notes, and snippets.

@YOUNGJUN2
Created July 3, 2019 06:55
Show Gist options
  • Save YOUNGJUN2/25a33d5c21ce5ff3fef489faf309264c to your computer and use it in GitHub Desktop.
Save YOUNGJUN2/25a33d5c21ce5ff3fef489faf309264c to your computer and use it in GitHub Desktop.
def solution(n):
n = str(n)
sum = 0
for i in range(len(n)):
sum += int(n[i])
return sum
# 문제: https://programmers.co.kr/learn/courses/30/lessons/12931
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment