The point of some of the exercises is to discourage the use of item deletion when mixed with item assignment. It is difficult to keep track of how the index values "shift" after item deletion: later chapters show better ways to write code than using such tricky item deletion.


Item Deletion and Assignment

N = list(range(11,18))
N[2] = True
del N[0], N[3]
N[2] = True
del N[0], N[3]
N[2] = True