摘要:
1、n串最长公共子序列 1 #include 2 #include 3 #include 4 using namespace std; 5 const int MAXF=1000005; 6 const int MAXN=105; 7 int n; 8 int base[MAXN],len[MAXN],pos[MAXN]; 9 char ans;10 char f[MAXF];11 char word[MAXN][MAXN];12 void solve()13 {14 int idx=0;15 for(int i=0;i<n;i++){16 idx+=(pos[... 阅读全文
摘要:
Ultra-QuickSortTime Limit:7000MSMemory Limit:65536KTotal Submissions:37971Accepted:13672DescriptionIn this problem, you have to analyze a particular sorting algorithm. The algorithm processes a sequence of n distinct integers by swapping two adjacent sequence elements until the sequence is sorted in 阅读全文
摘要:
StarsTime Limit:1000MSMemory Limit:65536KTotal Submissions:29888Accepted:13066DescriptionAstronomers often examine star maps where stars are represented by points on a plane and each star has Cartesian coordinates. Let the level of a star be an amount of the stars that are not higher and not to the 阅读全文