adplus-dvertising
frame-decoration

Question

What is the output of the code shown below?
random.seed(3)
random.randint(1,5)
2
random.seed(3)
random.randint(1,5)

a.

3

b.

2

c.

Any integer between 1 and 5, including 1 and 5

d.

Any integer between 1 and 5, excluding 1 and 5

Answer: (b).2

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. What is the output of the code shown below?