Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The contract of Random requires determinism, so the algorithm can never be changed.

> If two instances of Random are created with the same seed, and the same sequence of method calls is made for each, they will generate and return identical sequences of numbers. In order to guarantee this property, particular algorithms are specified for the class Random. Java implementations must use all the algorithms shown here for the class Random, for the sake of absolute portability of Java code



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: