Problem Description Nowadays, people have many ways to save money on accommodation when they are on vacation. One of these ways is exchanging houses with other people. Here is a group of N people who want to travel around the world. They live in diff…
Holiday's Accommodation Time Limit: 8000/4000 MS (Java/Others) Memory Limit: 200000/200000 K (Java/Others)Total Submission(s): 2009 Accepted Submission(s): 558 Problem Description Nowadays, people have many ways to save money on accommodation w…
Holiday's Accommodation Time Limit: 8000/4000 MS (Java/Others) Memory Limit: 200000/200000 K (Java/Others)Total Submission(s): 2925 Accepted Submission(s): 894 Problem Description Nowadays, people have many ways to save money on accommodation w…
pid=3966" target="_blank" style="">题目链接:hdu 3966 Aragorn's Story 题目大意:给定一个棵树,然后三种操作 Q x:查询节点x的值 I x y w:节点x到y这条路径上全部节点的值添加w D x y w:节点x到y这条路径上全部节点的值降低w 解题思路:树链剖分,用树状数组维护每一个节点的值. #pragma comment(linker, "/STACK:1024000000,1…
HDU Aragorn's Story 题目链接 树抛入门裸题,这题是区间改动单点查询,于是套树状数组就OK了 代码: #include <cstdio> #include <cstring> #include <vector> #include <algorithm> using namespace std; const int N = 50005; inline int lowbit(int x) {return x&(-x);} int dep…
题链:http://acm.hdu.edu.cn/showproblem.php?pid=5282 Senior's String Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) Total Submission(s): 142 Accepted Submission(s): 40 Problem Description Xuejiejie loves strings m…
主题链接:http://acm.hdu.edu.cn/showproblem.php? pid=3177 Problem Description Crixalis - Sand King used to be a giant scorpion(蝎子) in the deserts of Kalimdor. Though he's a guardian of Lich King now, he keeps the living habit of a scorpion like living und…
zhx's submissions Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) Total Submission(s): 540 Accepted Submission(s): 146 Problem Description As one of the most powerful brushes, zhx submits a lot of code on many o…