Answer the question
In order to leave comments, you need to log in
I don't understand why it doesn't return anything.
the function returns None and I don't understand why
a = input("Ведите числа: ")
def fun(a,r = 0):
if len(a) == 1:
print(a)
print(type(a))
return a
elif len(a)> 1:
for i in a:
r += int(i)
a = str(r)
fun(a)
print(fun(a))
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question