mardi 7 mars 2017

python random number guessing

my question may be little different. here is my code

from random import randint

print(randint(0,9))

Now i want to know which number it will generate if run this code.What is the algorithm behind it.is their a way i can change it.

if that does not work let me ask something different

from random import randint
for i in range(10):
    print(randint(0,9)) 

let take this example this will print 10 random number example list[2,1,4,5,2,4,5,2,1,5]

if i know 9 number in the above list is their a way to know 10 number for that instance.

Kudos to stackoverflow. Thanks a ton geeks




Aucun commentaire:

Enregistrer un commentaire