주하진이 매우 괜찮은 깨달음을 얻는 과정 Vol.1

This commit is contained in:
2020-04-29 20:23:12 +09:00
parent 0241857690
commit a4366d0b35
5 changed files with 62 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
N = int(input())
def seps(n):
return n + sum(map(int, str(n)))
for i in range(1 if N < 101 else N-100, N):
if seps(i) == N:
print(i)
break
else:
print(0)