First, you have to import random and time.
When you have finished, type in time.sleep(5)
We're using this to prevent a sudden crash.
You should now type in print(list(range(1,1000))) as your final line.
Your program should look like this:
If your system is literally crashing after importing modules without the use of
time.sleep(1), something's wrong. And what is
random for? If this post isn't a joke, it is nonsensical, to put it bluntly. The script doesn't even match what the text is saying.
range()? It is an object representing an immutable sequence of integers but isn't a list.
list() converts an iterable into a list. So we have:
Another way to create a list of numbers 1-1000 is to use a for loop and
append() each number (adds an item to the end of a list):
a =  for i in range(1, 1001): a.append(i) print(a) # Single line print statement print(list(i for i in range(1,1001)))
I can imagine the use of
time.sleep() to have the console "count" to 1000, printing one number at a time:
import time for i in range(1, 1001): print(i) time.sleep(.25)
Ctrl + C to stop (if not using repl.it's stop button).