Code Lab

Enumerate

a = ['a', 'b', 'c', 'd', 'e'] for index, item in enumerate(a): print(index, item)
:
Input
Input Data (stdin):
Output
0 a
1 b
2 c
3 d
4 e