树状数组维护DP + 高精度 Description These days, Sempr is crazed on one problem named Crazy Thair. Given N (1 ≤ N ≤ 50000) numbers, which are no more than 109, Crazy Thair is a group of 5 numbers {i, j, k, l, m} satisfying: 1 ≤ i < j < k < l < m ≤ N Ai…
http://poj.org/problem?id=1200 #include<iostream> #include<cstring> using namespace std; const int maxn=2e7; ],ans=; ]; char s[maxn]; int main(){ memset(vis,,); scanf("%d%d%s",&len,&base,s); int base1=base; //把字符串转换为base进制的数…