Loops with Ranges

Learn about fixed iteration loops, which have a large number of iterations with different intervals.

The range() function

The range() function is used to generate a sequence of values. For example, range(100) generates values 00 to 9999. If we provide two parameters to this function, like range(10,100), it generates values 1010 to 9999. It also makes it easy to specify the increment or jump value. For example, range(10,100,2) generates even values between 1010 and 9999.

Get hands-on with 1200+ tech skills courses.