Which of the following will give i the values 1, 2, 3, and 4?

for i in range (1, 5):
for i in range(0, 4):
for i in range (1, 4):
for i in range(0, 5):

The correct answer is:

for i in range (1, 5):

This will give the values 1, 2, 3, and 4 to the variable i as it iterates through the range starting at 1 and ending at 4 (but not including 5).