KnowledgeBoat Logo

Computer Science

The range() function is used to specify the number of iterations to be performed in for loop.

Python Control Flow

1 Like

Answer

True

Reason — In Python, the range() function is used to specify the number of iterations to be performed in a for loop. It generates a sequence of numbers that can be used to iterate over a block of code a specific number of times. The range() function takes parameters for the start, stop, and step values to define the range of numbers to be generated.

Answered By

2 Likes


Related Questions