Код: Выделить всё
def check_data(input_list):
for i in range(len(input_list)):
# logic goes here
x = 10
# ...
# more logic
return x
# why is x always 10?? It should be 2???
Подробнее здесь: https://stackoverflow.com/questions/798 ... ng-in-loop
Код: Выделить всё
def check_data(input_list):
for i in range(len(input_list)):
# logic goes here
x = 10
# ...
# more logic
return x
# why is x always 10?? It should be 2???