Im super new to Python, i'm still just trying to understand the syntax
I like to add a random integer variable to a list.
Online I found different examples, for appending multiple variable to a list,
for example; the extend function or using a range,
but i just want to append one random integer variable to a list
below you find my sad attempts
I like to add a random integer variable to a list.
Online I found different examples, for appending multiple variable to a list,
for example; the extend function or using a range,
but i just want to append one random integer variable to a list
below you find my sad attempts

from random import randint #store num answers = [] #Random gen num = randint(0, 9) print(num) #answers[num] #answers.append(num) #answers.insert(0, num) #answers = [random.randint(0,9)] #answers.extend(randint(0, 9)) print(answers)