Python – Random Number

 

RANDOM NUMBER IN PYTHON

 

Program

 

# Program to generate a random number

 

# import the random module

import random

 

a = int(input(‘Enter the lower limit: ‘))

b = int(input(‘Enter the upper limit: ‘))

 

print(random.randint(a,b))

 

input(“\nPress Enter to Exit”)

 

Output