adplus-dvertising
frame-decoration

Question

What is the interval of the value generated by the function random.random(), assuming that the random module has already been imported?

a.

(0,1)

b.

(0,1]

c.

[0,1]

d.

[0,1)

Posted under Python

Answer: (d).[0,1)

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 interval of the value generated by the function random.random(), assuming that the random module has already been imported?