for number in range(1,101): print number
Can someone please explain to me why the above code prints 1-100? I understand that the range functio
number is a variable in which each value in the range is placed.
range actually returns an iterator, and the for is responsible for advancing it through the range.