摘要:
参考自:http://blog.csdn.net/ice_crazy/article/details/7536332#include <iostream>#include <cstdio>#include <string.h>using namespace std;int n,s[999999],head[999999];int fun(){ int len,i,mid,l,r; memset(head,0,sizeof(head)); head[1]=s[1]; len=1; for (i=2;i<=n;++i)//采用二分查找 { l=1;... 阅读全文