摘要:
点击查看代码 #include<iostream> using namespace std; const int N =100010; int n; int q[N], tmp[N]; typedef long long LL; //最坏情况下逆序数为n*(n-1)/2 结果值会爆int LL me 阅读全文
摘要:
点击查看代码 #include<iostream> using namespace std; const int N = 100010; int n; int q[N], tmp[N]; void merge_sort(int q[], int l, int r){ if(l >= r) retur 阅读全文
摘要:
点击查看代码 #include<iostream> using namespace std; const int N = 100010; int n, k; int q[N]; int quick_sort(int l, int r, int k){ if(l == r) return q[l]; 阅读全文