170k views
5 votes
Question # 5

Fill in the Blank
Fill in the missing parts to produce the following output.

OUTPUT:
0
1
2
3

num in range(
):
print (num)

User Slimer
by
5.4k points

1 Answer

4 votes

for num in range(4):

print(num)

The output will be:

0

1

2

3

The for loop iterates through the numbers in the range function and prints those same numbers to the console.

User Tom Ashworth
by
5.4k points