enumerate in for loop

PHOTO EMBED

Mon Jan 03 2022 14:13:48 GMT+0000 (Coordinated Universal Time)

Saved by @ahoeweler

list = [1, 2, 3]

for index, height in enumerate(list):
print('index' + str(index) + ": " + str(height))

# use index + 1 if you don't want to start with "0"
content_copyCOPY