转义符表This all of the escape sequences Ruby supports. You may not use many of these, but memorize their format and what they do anyway. Try them out in ...
分类:
其他好文 时间:
2014-09-03 22:37:17
阅读次数:
222
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
Problem Description
Dragon is watching NBA. He loves James and Miami Heat.
Here's an introduction of basketball game:http://en.wikipedia.org/wiki/Basketball. However the game in Dragon's version...
分类:
其他好文 时间:
2014-08-26 15:38:56
阅读次数:
183
Little Hasan loves to play number games with his friends.One day they were playing a game where one of them will speak out a positive numberand the others have to tell the sum of its factors. The firs...
分类:
其他好文 时间:
2014-08-25 11:57:04
阅读次数:
235
题目描述:
Given an increasing sequence S of N integers, the median is the number at the middle position. For example, the median of S1={11, 12, 13, 14} is 12, and the median of S2={9, 10, 15, 16, 17} is 15. The median of two sequences is defined to be...
分类:
其他好文 时间:
2014-08-24 19:24:22
阅读次数:
235
??ZCC Loves CodefiresTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 223Accepted Submission(s): 12...
分类:
其他好文 时间:
2014-08-23 13:53:30
阅读次数:
207
题目链接Jane loves string more than anything. She made a function related to the string some days ago and forgot about it. She is now confused about calcu...
分类:
其他好文 时间:
2014-08-22 19:36:09
阅读次数:
294
给N个升序的数字,要求找出一个子串,每相邻两个数字不互质,求最长串的长度
提示
1)dp[i]表示到第i个数字的最长串
2)dp[i]用前i-1项中与第i项不互质的最大项更新
3)寻找与第i项不互质,即找与第i项有公公因数,所以建立数组dig[i]表示该因数出现的次数
#include
#include
#define maxn 100005
int dp[maxn];
int di...
分类:
其他好文 时间:
2014-08-17 18:38:52
阅读次数:
197