楼主: yghb
9784 2

[问答] 【求助】请教 excel 中 rnd函数和 rand函数的区别 [推广有奖]

  • 0关注
  • 0粉丝

大专生

6%

还不是VIP/贵宾

-

威望
0
论坛币
4 个
通用积分
0
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
284 点
帖子
31
精华
0
在线时间
19 小时
注册时间
2010-2-25
最后登录
2013-9-14

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
.
请教 excel 中 rnd函数和 rand函数的区别是什么?用哪个函数产生的随机数的均匀性,随机性更好?


版主:Rand()是excel的函数,RND()仅适用于VBA.
Rand FunctionIn Excel, the Rand function returns a random number that is greater than or equal to 0 and less than 1. The Rand function returns a new random number each time your spreadsheet recalculates.
The syntax for the Rand function is: Rand( )

Note:
To create a random number between two numbers, you can use the following formula:
=Rand()*(b-a)+a
Where a is the smallest number and b is the largest number that you want to generate a random number for. Please note, that this formula will never generate a number at the highest end of the range.
=Rand()*(25-10)+10
The formula above would generate a random number between 10 and 24.9999999.

Applies To: Excel 2007, Excel 2003, Excel XP, Excel 2000

-------------------------------
Rnd Function (VBA only)In Excel, the Rnd function allows you to generate a random number (integer value). You can specify the random number to be a value between 2 user-specified numbers.
The syntax for the Rnd function is:
Int ((upperbound - lowerbound + 1) * Rnd + lowerbound)
upperbound is the highest value that the random number can be.
lowerbound is the lowest value that the random number can be.

Applies To:
  • Excel 2007, Excel 2003, Excel XP, Excel 2000


可参考:
http://slamkk.blog.163.com/blog/static/256110920107393120550/
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

关键词:EXCEL xcel rand exce cel 请教 EXCEL 函数 rand rnd

沙发
wang1568 发表于 2011-6-19 07:05:40 |只看作者 |坛友微信交流群
rnd 是VBA函数
rand 是工作表函数
听说,rand() 较好 ????

http://support.microsoft.com/default.aspx?scid=kb;en-us;231847&Product=vbb
已有 1 人评分经验 论坛币 学术水平 热心指数 收起 理由
liuzhenzhu + 20 + 8 + 1 + 2 热心帮助其他会员

总评分: 经验 + 20  论坛币 + 8  学术水平 + 1  热心指数 + 2   查看全部评分

使用道具

藤椅
tssyzl123 发表于 2011-6-20 12:11:57 |只看作者 |坛友微信交流群
很好很好很好恨好

使用道具

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注cda
拉您进交流群

京ICP备16021002-2号 京B2-20170662号 京公网安备 11010802022788号 论坛法律顾问:王进律师 知识产权保护声明   免责及隐私声明

GMT+8, 2024-6-17 13:16