Im loop though dictionary using
for key, value in mydict.items():
And I was wondering if any pythonic way also has access to the loop / iteration number of the loop. Get access to the index, while maintaining access to information about the key value.
for key, value, index in mydict.items():
this is because I need to detect the first cycle of the cycle. So inside I can have something like
if index != 1:
python dictionary
binarysmacker
source share