dimanche 30 décembre 2018

What are use cases to hand over different numbers in random.seed( 0 )

What are use cases to hand over different numbers in random.seed(0)?

import random
random.seed(0)
random.random() 

For example, to use random.seed(17) or random.seed(9001) instead of always using random.seed(0). Both return the same "pseudo" random numbers that can be used for testing.

import random
random.seed(17)
random.random() 

Why dont use always random.seed(0)?




Aucun commentaire:

Enregistrer un commentaire