![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
树形DP
文章平均质量分 86
cq_phqg
心中的坚持与不懈的努力,梦想就在前方!
展开
-
UVALive 6712(2013长春区域赛)
Three countries, Red, Yellow, and Blue are in war. The map of battlefield is a tree, which means that there are N nodes and (N −1) edges that connect all the nodes. Each country has a base station loc原创 2014-08-02 21:45:31 · 699 阅读 · 0 评论 -
2014多校1(1003)hdu4863
#include //树形dp,好题 #include #include #include using namespace std; #define INF ((1<<31)-1) #define mod 10007 int n,d; int head[210]; int next[210<<1]; int edge[210<<1]; int num[210];原创 2014-08-02 20:10:46 · 848 阅读 · 1 评论 -
2014多校5(1006)hdu4916(树形DP)
Count on the path Time Limit: 5000/2500 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others) Total Submission(s): 255 Accepted Submission(s): 59 Problem Description bobo has原创 2014-08-06 16:42:30 · 677 阅读 · 0 评论 -
2014多校5(1002)hdu4912(贪心+LCA)
#include #include #include #include #include #pragma comment(linker, "/STACK:16777216") using namespace std; #define maxn 100010 int m,n; int head[maxn]; int edge[maxn<<1]; int next[原创 2014-08-06 16:53:01 · 669 阅读 · 0 评论 -
Codeforces Round #263 (Div. 2)D(树形DP)
D. Appleman and Tree time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Appleman has a tree with n vertices. S原创 2014-08-27 15:55:18 · 1110 阅读 · 1 评论 -
Codeforces Round #277 (Div. 2)D(树形DP计数类)
D. Valid Sets time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output As you know, an undirected connected graph wit原创 2014-11-12 11:06:35 · 1311 阅读 · 0 评论 -
ASC(1)C(树形DP)
New Year Bonus Grant Special JudgeTime Limit: 6000/3000MS (Java/Others)Memory Limit: 128000/64000KB (Java/Others) SubmitStatisticNext Problem Problem Description All programmers原创 2014-10-02 01:07:04 · 853 阅读 · 0 评论 -
Codeforces Round #275 (Div. 1)D(树形DP)
D. Random Function and Tree time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You have a rooted tree consistin原创 2014-11-13 16:40:18 · 948 阅读 · 0 评论