I tried to code it using randint and got an attribute error for it.
import random
def generate(start,end,n):
res=[]
for j in range(n):
res.append(random.randint(start,end))
return res
start=1
end=15
n=5
print(generate(start,end,n))
The interpreter produced the following error:
AttributeError: module 'random' has no attribute 'randint'
This code doesn't raise an error in idle.