Welcome to bytea
当前位置: Home 学习资料 网站制作 php生成随机数-rand() 今天是...date...

登录bbs

用户名
密码

bytea统计

Members : 43193
Content : 343
Web Links : 69
php生成随机数-rand() PDF Print E-mail
Sunday, 20 March 2005 08:07

rand

取得随机数值。

语法: int rand([int min], [int max]);

返回值: 整数

函数种类: 数学运算

内容说明:

本函数用来取得随机数值。若没有指定随机数的最大及最小范围,本函数会自动的从 0 到 RAND_MAX 中取一个随机数。若有指定 min 及 max 的参数,则从指定参数中取一个数字。例如 rand(38, 49) 则会从 38 到 49 之间取一个随机数值,UNIX 系统包含 49、Win32 系统不包含 49 ( This e-mail address is being protected from spambots. You need JavaScript enabled to view it 10-May-1999)。值得注意的是为使随机数的乱度最大,每次在取随机数之前最好使用 srand() 以配置新的随机数种子。

应用:在本站的许愿板(漂流瓶和许愿云)中,使用此函数使各个愿望的前进速度不同。

Comments (5)Add Comment
谢谢
written by 丽江旅游, October 05, 2009
谢谢了,我是一个初学者
report abuse
vote down
vote up
Votes: +3
...
written by pretty girls, March 06, 2010
http://www.pecy.org
report abuse
vote down
vote up
Votes: +2
...
written by MurrayJENNY19, August 04, 2010
I took 1 st loan when I was very young and it supported my business very much. But, I require the credit loan once more time.
report abuse
vote down
vote up
Votes: +2
...
written by nice-[url=http://www.cheaphandbags.ru/mayburry-replica-224.html]discount Mayburry handbags[/url], May 23, 2011
nice-discount Mayburry handbags
report abuse
vote down
vote up
Votes: +1
...
written by 妈妈点评网, January 10, 2012
买东西,先上妈妈点评网,分享交流购物 验!
http://www.xinxingyuan.net.cn
report abuse
vote down
vote up
Votes: +0

Write comment
quote
bold
italicize
underline
strike
url
image
quote
quote
smile
wink
laugh
grin
angry
sad
shocked
cool
tongue
kiss
cry
smaller | bigger

security code
Write the displayed characters


busy
 

支持本站:



Connect with me via QQ:38074 or e-mail:

©2006 bytea.net All Copyrights Reserved.

本站备案编号:保密^_^

RSS:  

开启背景音乐