6. Use enumerate(start=…) for numbered loops

Use enumerate(..., start=1) instead of adding offsets inside the loop body.

Putting the starting offset in the iterator setup is easier to spot than adding 1 or another offset in several places inside the loop. It keeps numbering policy out of the loop body.

6.1. Don’t do this

1for i, name in enumerate(names):
2    print(i + 1, name)

6.2. Do this

1for i, name in enumerate(names, start=1):
2    print(i, name)