How to get the index for items in a 'for' loop
a_list = ["icecream","lemon cake","chocolate cake"]
for index, value in enumerate(a_list):
print(index, index)
SNAPPED!

SNAPPED!
a_list = ["icecream","lemon cake","chocolate cake"]
for index, value in enumerate(a_list):
print(index, index)
SEND TO YOURSELF, SAVE FOR LATER, OR SHARE WITH YOUR TEAM!
SEND TO YOURSELF, SAVE FOR LATER, OR SHARE WITH YOUR TEAM!
SNAPPED!
Comments
Post a Comment