查最小值,删除,翻转... 显然splay啊... #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #define N 200005 #define inf 0x3f3f3f3f using namespace std; int n; ], fa[N]; int a[N]; int mn[N],zhi[N],size[N]; void push_up(int…
1014: [JSOI2008]火星人prefix Time Limit: 10 Sec Memory Limit: 162 MBSubmit: 6243 Solved: 2007[Submit][Status][Discuss] Description 火星人最近研究了一种操作:求一个字串两个后缀的公共前缀.比方说,有这样一个字符串:madamimadam,我们将这个字符串的各个字符予以标号:序号: 1 2 3 4 5 6 7 8 9 10 11 字符 m a d a m i m a d…
Robotic Sort Time Limit: 6000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3913 Accepted Submission(s): 1717 Problem Description Somewhere deep in the Czech Technical University buildings, there are labora…