way to do the same with simple for in :-style loopbecause such loop iterates through actual itemsnot list positions but what about the equivalent while loopsuch loop requires bit more work on our partand might run more slowly depending on your python (it does on and though less so on --we'll see how to verify this in ) while len( ) [ + + [ here againthoughthe range solution may not be ideal either list comprehension expression of the form[ for in llikely runs faster today and would do similar workalbeit without changing the original list in place (we could assign the expression' new list object result back to lbut this would not update any other references to the original listbecause this is such central looping conceptwe'll save complete exploration of list comprehensions for the next and continue this story there parallel traversalszip and map our next loop coding technique extends loop' scope as we've seenthe range builtin allows us to traverse sequences with for in nonexhaustive fashion in the same spiritthe built-in zip function allows us to use for loops to visit multiple sequences in parallel--not overlapping in timebut during the same loop in basic operationzip takes one or more sequences as arguments and returns series of tuples that pair up parallel items taken from those sequences for examplesuppose we're working with two lists ( list of names and addresses paired by positionperhaps) [ , , , [ , , , to combine the items in these listswe can use zip to create list of tuple pairs like rangezip is list in python xbut an iterable object in where we must wrap it in list call to display all its results at once (againthere' more on iterables coming up in the next zip( list(zip( )[( )( )( )( )list(required in xnot such result may be useful in other contexts as wellbut when wedded with the for loopit supports parallel iterationsloop coding techniques