2014-09-25 BaoXinjian一、摘要在官方文档《oracle performance tuning guide》中提到Connecting to the database is an expensive operation that is highly unscalable。数据库的连...
分类:
数据库 时间:
2014-10-14 22:50:39
阅读次数:
222
HDU 3397 Sequence operation
题目链接
题意:给定一个01序列,有5种操作
0 a b [a.b]区间置为0
1 a b [a,b]区间置为1
2 a b [a,b]区间0变成1,1变成0
3 a b 查询[a,b]区间1的个数
4 a b 查询[a,b]区间连续1最长的长度
思路:线段树线段合并,需要两个延迟标记一个置为01,一个翻转,然后由...
分类:
其他好文 时间:
2014-10-13 22:18:57
阅读次数:
278
Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation is counted as 1 step.)
You have the following 3 operations permitted on a word:...
分类:
其他好文 时间:
2014-10-13 20:08:07
阅读次数:
188
Problem Description
You have an array consisting of n integers: a1=1,a2=2,a3=3,…,an=n.
Then give you m operators, you should process all the operators in order. Each operator is one of four types...
分类:
其他好文 时间:
2014-10-12 22:56:58
阅读次数:
311
Operation the Sequence
Time Limit: 3000/1500 MS (Java/Others) Memory Limit: 32768/32768
K (Java/Others)
...
分类:
其他好文 时间:
2014-10-12 11:38:17
阅读次数:
332
Operation the SequenceTime Limit: 3000/1500 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 154Accepted Submission(s): 7...
分类:
其他好文 时间:
2014-10-12 04:19:54
阅读次数:
193
http://acm.hdu.edu.cn/showproblem.php?pid=5063题目大意: 题目意思还是比较简单。所以就不多少了。注意这句话,对解题有帮助。 Type4: Q i query current value of a[i], this operator will have.....
分类:
其他好文 时间:
2014-10-12 02:23:37
阅读次数:
124
HDU 5063 Operation the Sequence
题目链接
把操作存下来,由于只有50个操作,所以每次把操作逆回去运行一遍,就能求出在原来的数列中的位置,输出即可
代码:
#include
#include
#include
using namespace std;
typedef long long ll;
const int N = 100005;...
分类:
其他好文 时间:
2014-10-12 00:30:07
阅读次数:
262
1 #include 2 #include 3 #include 4 5 #define MAXN 100005 6 #define MOD 1000000007 7 int que[MAXN], front = 0, rear = 0; 8 int n; 9 10 void query(...
分类:
其他好文 时间:
2014-10-12 00:27:06
阅读次数:
302