华光大帝宝诰:RAND()最大支持的的随机数范围是多少?

来源:百度文库 编辑:中科新闻网 时间:2024/05/08 01:27:35
C++里面RAND()能产生的最大随机数的范围是多大?
是不是仅限制与INT型所能支持的数范围?

The rand function returns a pseudorandom integer in the range 0 to RAND_MAX.

The constant RAND_MAX is the maximum value that can be returned by the rand function. RAND_MAX is defined as the value 0x7fff.