Windows-equivalent of POSIX srandom(…) and random() functions?
问题 I'm trying to port some code over from UNIX to Windows, and I need an implementation of POSIX srandom(x) and random() functions that, for a given seed x , generate the same number sequence as the one that conforms to POSIX.1-2001. What are some of the available options on Windows? 回答1: srandom and family are members of glibc. You can probably copy the source code from glibc for srandom/random into your application, as long as it's license compatible. If you're looking for another