• Welcome to ComeFromChina Community (CFC中文网)! We are the largest Chinese Canadian community forum in Ottawa. Please to participate in discussions, post topics, view images, and access full community features. Join us today! 欢迎来到CFC中文网。请登录以参与讨论、发布主题并查看图片。

好,这回来个原创的题,挑战一下我村的高手们!

庄家以算术级数増长,而玩家以几何级数增长.
 
这个庄应该这么设局:

这是个简单的掷骰子游戏。每次游戏开始前玩家必须先付庄家2元,
如果第一次,掷到"6", 庄家付玩家6元.
if (nextPlay == "Yes"), player pay extra 2*2 = 4,
if (掷到"6") { 庄家付玩家6*6=36元 }
else if (nextPlay == "Yes")
, player pay extra 2*2*2 = 8,
if (掷到"6") { 庄家 付玩家6*6*6=216元, }
else if (nextPlay == "Yes"), player pay extra 2*2*2*2 = 16,
if (掷到"6") { 庄家 付玩家6*6*6*6=1296元,}
.........................

看上面的红字。如果没掷到6,你说不能再玩了。但是code里,"nextplay" is in the "elseif" statement. 怎么解释啊?

您的规则把俺搞糊涂了。
 
Mathematical Expectation of the player's gain

E(p) = (1/6)*2 + (5/6)*(1/6)*(2*2) + (5/6)*(5/6)*(1/6)*(2*2*2) + ...
= (1/6)*2*[1 + (5/6)*2 + ((5/6)*2)*((5/6)*2) + ((5/6)*2)*((5/6)*2)*((5/6)*2) + ...]
= (1/6)*2*[1+ (5/3) + (5/3)*(5/3) + (5/3)*(5/3)*(5/3) +...]

The RHS of the equation is infinity.
 
看上面的红字。如果没掷到6,你说不能再玩了。但是code里,"nextplay" is in the "elseif" statement. 怎么解释啊?

您的规则把俺搞糊涂了。


如果没掷到6,不能再玩了, 结束, 从头开始. :D:D:D
 
如果没掷到6,不能再玩了, 结束, 从头开始. :D:D:D

老兄,您这题正经出的好!好象不象您楼上想的那么简单。

但麻烦您把code和规则再整理清晰一点,省着俺瞎忙乎。

俺抽空好好做一下,下周找个时间交作业。行不?您也抽空给俺的黄蓉贴捧捧场。
 
庄家最多可以允许玩家掷12次然后从头再

庄家最多可以允许玩家掷12次然后从头再来,still keep a margin of winning
 
后退
顶部
首页 论坛
消息
我的