I have to create a program where the user input asks how many numbers in an array and you have to print those numbers from an array.
Example:
How many values to add to the array:
12
[14, 64, 62, 21, 91, 25, 75, 86, 13, 87, 39, 48]
I don't know how to get all the numbers in one line and how to get different numbers each time. This is what I have so far:
import random
x = int(input("How many values to add to the array: "))
b = random.randint(1,99)
c = random.randint(1,99)
for i in range(x):
twainQuotes = [random.randint(b,c)]
for i in range(x-1):
print(twainQuotes)