0
What is the logic behind (for word in words:)??
3 Respuestas
+ 2
words is a list, and the syntax for word in words: will execute the loop code for every value of words (they will be stored one after the other in word)
example :
words=["Hello","world"]
for word in words:
print(word)
output :
Hello
world
+ 1
thank you very much ☺
+ 1
my pleasure :)