摘要:
#include<bits/stdc++.h> using namespace std; inline int read() { int x=0,f=1; char ch=getchar(); while(ch<'0'||ch>'9'){if(ch=='-') f=-1; ch=getchar(); 阅读全文
posted @ 2021-05-23 11:45
飞。畅
阅读(34)
评论(0)
推荐(0)
摘要:
题目描述 桌面上有R张红牌和B张黑牌,随机打乱顺序后放在桌面上,开始一张一张地翻牌,翻到红牌得到1美元,黑牌则付出1美元。可以随时停止翻牌,在最优策略下平均能得到多少钱。 输入格式 一行输入两个数R,B,其值在0到5000之间 输出格式 在最优策略下平均能得到多少钱。 样例 样例输入 5 1 样例输 阅读全文
posted @ 2021-05-22 18:33
飞。畅
阅读(94)
评论(0)
推荐(0)
摘要:
#include<bits/stdc++.h>using namespace std;const double eps=1e-8;int n;double a[60][60],ans[60];int main(){ cin>>n; for(int i=1;i<=n;i++) for(int j=1; 阅读全文
posted @ 2021-05-18 15:33
飞。畅
阅读(39)
评论(0)
推荐(0)
浙公网安备 33010602011771号