呵呵
#include
#include
#include
#include
typedef long long ll;
using namespace std;
const int N = 5 * 10000 + 5;
int xval[N], dep;
int n, a[N], pre[N];
ll d[N];
int pos[300], dd;
void work() {
d...
分类:
其他好文 时间:
2014-09-14 20:49:28
阅读次数:
211
尽可能凑2^x-1
#include
#include
const int N = 100005;
int a[N], p[N];
int init(int x) {
int cnt = 0;
while(x > 1) {
x /= 2;
cnt ++;
}
return cnt + 1;
}
int main() {
int n;
while(~scanf("%d", ...
分类:
其他好文 时间:
2014-09-14 20:49:07
阅读次数:
165
chp居然没来。。然后我跟zmc鼓捣了一下午。。出了3题 有一道貌似是DP水题。。然后我俩都不会dp。。A题水题不说了,E题博弈论模板。。然后我俩也都不会博弈论。。现场找的模板。。F题无脑BFS。。一开始看成计算几何了没敢做sad。。
A题:
Post Robot
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 6553...
分类:
其他好文 时间:
2014-09-14 20:48:37
阅读次数:
387
默默的签到Osu!http://acm.hdu.edu.cn/showproblem.php?pid=5003 1 #include 2 #include 3 using namespace std; 4 int a[64]; 5 int main(){ 6 int t,n; 7 w...
分类:
其他好文 时间:
2014-09-14 20:32:27
阅读次数:
262
Post Robothttp://acm.hdu.edu.cn/showproblem.php?pid=5007字符串比较 1 #include 2 char a[110]; 3 char A[]="MAI MAI MAI!"; 4 char B[]="SONY DAFA IS GOOD!"; 5 ...
分类:
其他好文 时间:
2014-09-14 20:32:07
阅读次数:
222
Problem DescriptionAfter eating food from Chernobyl, DRD got a super power: he could clone himself right now! He used this power for several times. He...
分类:
其他好文 时间:
2014-09-14 12:39:27
阅读次数:
299
这次。。啥也不说了 chp他两上课来晚了。。我也没账号。。开场半小时才开始做的,就敲了一道水题。。然后他们两一直在商量那道计算几何。。最后还是没出来。
Osu!
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)
Total Submission(s): 140 Acce...
分类:
其他好文 时间:
2014-09-14 00:10:26
阅读次数:
309
【B】RotateTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/65536 K (Java/Others) Special Judge【Problem Description】Noting is more interesting ...
分类:
其他好文 时间:
2014-09-14 00:02:46
阅读次数:
509
http://acm.hdu.edu.cn/showproblem.php?pid=5001
思路:dp计算出途径每个点的总概率,1-x即为所求解。
dp题,先介绍下dp[i][j]为第j步走在第i个点的概率,那么dp[i][j]=dp[x1][j-1]+dp[x2][j-1]+...,x1,x2为i 的相邻节点。上一步在相邻节点这一步才能走到该点嘛。
每个点概率要一个一个的算,当算到第ii...
分类:
其他好文 时间:
2014-09-13 21:28:55
阅读次数:
193
已经确定了的。。。B Rotate 1 /* 2 ID:esxgx1 3 LANG:C++ 4 PROG:B 5 */ 6 #include 7 #include 8 #include 9 #include 10 #include 11 using namespace std;12 13 st...
分类:
其他好文 时间:
2014-09-13 20:02:15
阅读次数:
193