RANGE FUNCTION
In repl.it, create a new Python file and name it range (click the pencil icon at the top to rename a file).
Type the following code into the editor (white panel) and run it.
for x in range(10): print(x)
What does it do?
3. A range can be defined with 2 values. Try replacing the previous range with this new one.
for x in range(50, 100): print(x)
4. Now let's add a third value.
for x in range(50, 100, 5): print(x)
4. Finally, rewrite the program to print every decade since 1880 until now.
That's it. Make sure the file is named 'range' so you can get credit for your work.
By Michelle Lim