07 2015 档案
摘要:#归并排序defmergeSort(a,L,R):if(L>=R):returnmid=((L+R)>>1)mergeSort(a,L,mid)mergeSort(a,mid+1,R)p=Lq=mid+1t=[]while(pa[q]:t.append(a[q])q+=1while(pval])a=...
阅读全文
摘要:voidQsort(int*a,intL,intR){if(L>=R)return;intp=L,q=R;intval=a[L];while(p!=q){while(pval)q--;if(p=R)return;intmid=(L+R)>>1;mergeSort(a,t,L,mid);mergeSo...
阅读全文
摘要:solution : 就按题解敲了一遍,好久没写这种dp1#include2#include3#include4#include5#include6#include7usingnamespacestd;8typedeflonglongLL;9constintMAX=1e3+10;10constint...
阅读全文
摘要:#includeusingnamespacestd;constintMAX=1e5+10;vectorfilter(constvector&vec,intval,less<){vectornvec;vector::const_iteratoriter=vec.begin();while((ite...
阅读全文

浙公网安备 33010602011771号