rangeGenerator
Creates a generator, that generates all values in the given range using the given step.
- Use a
while
loop to iterate fromstart
toend
, usingyield
to return each value and then incrementing bystep
. - Omit the third argument,
step
, to use a default value of1
.