HDU 4586 Play the Dice(概率+期望)...
分类:
其他好文 时间:
2015-05-11 20:10:24
阅读次数:
150
游戏在线预览地址:http://dtdxrk.github.io/game/3d-dice/index.htmljs判断一个随机数大小的游戏。本来想用canvas做的,平面的生产一个点数,感觉没啥意思。结合CSS3来吧,正好温习一下css3的3d属性。CSS具体实现过程【CSS3练习】3D盒子制作
分类:
Web程序 时间:
2015-05-10 06:14:51
阅读次数:
119
推出的公式是M^x*x/N,大概意思是M^x*x这些种可能后一定会找出一个裁判,在除以N为数学期望。
可能和数学公式还有关系。
#include
#include
__int64 gcd(__int64 a,__int64 b){
return b == 0 ? a : gcd(b, a%b);
}
int main()
{
__int64 i,j,n,m,t,x,a,b,te...
分类:
其他好文 时间:
2015-05-06 23:06:07
阅读次数:
205
题意:有两个人 每个人可以撒两个骰子 给出每个骰子的最大和最小值 谁撒出的数值和大谁获胜思路: 把两个人可能的值区间算出 因为是均匀分布 所以两人重叠的区间胜率相同 那么 只需计算谁获胜的区间大即可得出结果#include#include#include#include#include#...
分类:
其他好文 时间:
2015-05-05 23:28:19
阅读次数:
141
Given a dice with n sides, you have to find the expected number of times you have to throw that dice to see all its faces at least once. Assume that the dice is fair, that means when you throw the dic...
分类:
其他好文 时间:
2015-05-01 12:08:28
阅读次数:
141
Given a dice with n sides, you have to find the expected number of times you have to throw that dice to see all its faces at least once. Assume that the dice is fair, that means when you throw the dice...
分类:
其他好文 时间:
2015-04-30 18:22:36
阅读次数:
99
Dice GameTime Limit: 1000msMemory Limit: 524288KBThis problem will be judged onCodeForcesGym. Original ID:100502D64-bit integer IO format:%I64d Java c...
分类:
其他好文 时间:
2015-04-27 23:13:09
阅读次数:
189
Description
Input
Output
Sample Input
1 4 1 4
1 6 1 6
Sample Output
Emma
HINT
Source
NCPC 2014
题意:两个人丢色子,每人有两个色子,给出色子的大小,要...
分类:
其他好文 时间:
2015-04-26 18:22:34
阅读次数:
144
#include
#include
#include
using namespace std;
double sumg,sume;
int ga1,gb1,ga2,gb2,ea1,eb1,ea2,eb2;
int main ()
{
while (scanf("%d%d%d%d",&ga1,&gb1,&ga2,&gb2)!=EOF)
{
...
分类:
其他好文 时间:
2015-04-26 18:21:09
阅读次数:
124
Problem Description
You have a dice with m faces, each face contains a distinct number. We assume when we tossing the dice, each face will occur randomly and uniformly. Now you have T query to answer...
分类:
其他好文 时间:
2015-04-24 09:14:08
阅读次数:
131