jeudi 15 décembre 2016

systemVerilog- how can I use $urandom/$random with range?

Is there a way to use $urandom/$random with range?

I succeeded to do it with max range in the following way (in this case 11 is the max range):

 temp = (($urandom(9)%11));

But how can I do it for max and min, for example max=11, min =8.




Aucun commentaire:

Enregistrer un commentaire