youyou09 @ 2024-08-11 13:48:42
这道题卡爆力都能拿50分耶!(正解我知道,只是感叹一下)
#include<bits/stdc++.h>
using namespace std;
int a[5000005];
int main(){
int n,sum=0;cin>>n;
for (int j=1;j<=n;j++){
cin>>a[j];
for (int i=1;i<=j;i++){
if(a[j]<a[i])sum++;
}
}
cout<<sum;
return 0;
}
支持互关
by meifan666 @ 2024-08-11 13:53:00
@youyou09 对于 50% 的数据,n<=4e4
by __zhy__ @ 2024-08-11 13:53:10
@youyou09 对于
by youyou09 @ 2024-08-11 13:57:20
@meifan666 @zhy 晓得啦
by AnnaQ @ 2024-10-18 15:33:45
暴力能拿50分我兢兢业业的写树状数组喜提0pts呜呜呜