题意:
给定n个点m条边的无向图
每次必须沿着LOVE走,到终点时必须是完整的LOVE,且至少走出一个LOVE,
问这样情况下最短路是多少,在一样短情况下最多的LOVE个数是多少。
有自环。
#include
#include
#include
#include
#include
#include
using namespace std;
typedef __int64 ll...
分类:
其他好文 时间:
2014-09-28 20:22:06
阅读次数:
186
Aeroplane chess
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 1503 Accepted Submission(s): 1025
Problem Description
Hzz loves ...
分类:
其他好文 时间:
2014-09-28 18:01:25
阅读次数:
210
题目大意:1 l r x操作 讲 [l,r]上的节点涂成x颜色,而且每一个节点的值都加上 |y-x| y为涂之前的颜色2 l r 操作,求出[l,r]上的和。思路分析:假设一个区间为同样的颜色。那么我们才干够合并操作。所以我们之前找同样的区间就好。可是问题是怎样合并操作。那么我们定义一个val 表示...
分类:
其他好文 时间:
2014-09-25 14:18:49
阅读次数:
242
Tower Defense
Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 132768/132768 K (Java/Others)
Total Submission(s): 474 Accepted Submission(s): 126
Problem Description
DRD loves...
分类:
其他好文 时间:
2014-09-17 18:43:22
阅读次数:
367
DZY has a sequence a, consisting of
n integers.
We'll call a sequence ai,?ai?+?1,?...,?aj
(1?≤?i?≤?j?≤?n) a subsegment of the sequence
a. The value (j?-?i?+?1) denotes the length of the subsegmen...
分类:
其他好文 时间:
2014-09-16 15:57:40
阅读次数:
248
Description
Alexander Charles McMillan loves to gamble, and during his last trip to the casino he ran across a new game. It is played on a linear sequence of squares as shown below.
A chip is in...
分类:
其他好文 时间:
2014-09-06 12:31:33
阅读次数:
275
ZCC Loves CodefiresTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 790Accepted Submission(s): 420P...
分类:
其他好文 时间:
2014-09-05 18:08:01
阅读次数:
141
GG,,,g艹#include #include #include #include #include #include #include using namespace std;vectorG[21][7];//G[i][j] 表示n=i k=j的情况下 二进制的状态int n, k, l;int...
分类:
其他好文 时间:
2014-08-30 18:56:59
阅读次数:
182
题目链接Devendra loves the XOR operation very much which is denoted by∧sign in most of the programming languages. He has a listAofNnumbers and he wants to...
分类:
其他好文 时间:
2014-08-27 21:53:08
阅读次数:
316
??
题意 有n个题目 完成第i个题目需要的时间为e[i] 第i个题目的系数为k[i] 你可以按任意顺序完成题目 比赛开始到完成第i个题目消耗的总时间为t[i] 那么完成第i个题目要扣掉k[i]*t[i]分 求完成所有题目至少扣多少分
考虑任意相邻两题i,j 改变i,j时 i,j之前和之后所有的题目对结果都没有影响 只是i,j两题的扣分和由原来的(t+e[i])*...
分类:
其他好文 时间:
2014-08-27 10:58:07
阅读次数:
264