Im having a trouble here, I need to create a function for an empty list with 4 digits random numbers, which I did
import random
def numerosazar(n):
random_numeros=[]
for i in range(n):
random_numeros.append(random.randint(1000,10000))
return random_numeros
The problem is I need it to also give me an ammount of number of 2 digits which I did but not as function
azar=numerosazar(random.randint(10,100))
print("Los numeros de la lista son: ",azar, "\n")
So im having trouble mixing them together (sorry if my english is not good enough btw)
source https://stackoverflow.com/questions/73521530/mixing-2-functions-as-1
Comments
Post a Comment