提交记录 17222
| 提交时间 |
评测时间 |
| 2021-12-19 15:08:53 |
2021-12-19 15:08:59 |
#include<bits/stdc++.h>
using namespace std;
const int N=1e8+5,M=260;
int m=(1<<8)-1;
unsigned b[N],c1[M],c2[M],c3[M],c4[M];
void sort(unsigned *a,int n){
for(int i=0;i<n;i++)
c1[a[i]&m]++,c2[(a[i]>>8)&m]++,c3[(a[i]>>16)&m]++,c4[a[i]>>24]++;
for(int i=1;i<=m;i++)
c1[i]+=c1[i-1],c2[i]+=c2[i-1],c3[i]+=c3[i-1],c4[i]+=c4[i-1];
for(int i=n-1;i>=0;i--) b[--c1[a[i]&m]]=a[i];
for(int i=n-1;i>=0;i--) a[--c2[(b[i]>>8)&m]]=b[i];
for(int i=n-1;i>=0;i--) b[--c3[(a[i]>>16)&m]]=a[i];
for(int i=n-1;i>=0;i--) a[--c4[b[i]>>24]]=b[i];
}
| Compilation | N/A | N/A | Compile OK | Score: N/A | 显示更多 |
| Testcase #1 | 1.066 ms | 820 KB | Accepted | Score: 34 | 显示更多 |
| Testcase #2 | 1.131 s | 762 MB + 996 KB | Accepted | Score: 33 | 显示更多 |
| Testcase #3 | 2.866 s | 1144 MB + 464 KB | Runtime Error | Score: 0 | 显示更多 |
Judge Duck Online | 评测鸭在线
Server Time: 2026-03-17 23:45:50 | Loaded in 1 ms | Server Status
个人娱乐项目,仅供学习交流使用 | 捐赠