提交记录 15621


用户 题目 状态 得分 用时 内存 语言 代码长度
comprehension 1001. 测测你的排序 Time Limit Exceeded 0 5 s 354028 KB C++11 496 B
提交时间 评测时间
2021-01-05 19:13:05 2021-01-05 19:13:14
template<typename Type>
void sort(Type*const&first,Type*const&last){//[first,last)
	int number=last-first,half=number>>1;
	if(first!=last-1){
Type*	const middleF=first+half,
	*	const temp=new Type[number],
	*	const tlast=temp+number,
	*i=first,*j=middleF,*t=temp;
		sort(first,middleF),sort(middleF,last);
		for(;t!=tlast;)
			*t++= i!=middleF and (j==last or *i<*j)?*i++:*j++;
		for(i=first;i<last;++i)
			*i=temp[i-first];
		delete temp;
	}
}
void sort(unsigned *a, int n) {
	sort(a, a + n);
}

CompilationN/AN/ACompile OKScore: N/A

Testcase #15 s345 MB + 748 KBTime Limit ExceededScore: 0


Judge Duck Online | 评测鸭在线
Server Time: 2026-03-20 13:08:46 | Loaded in 1 ms | Server Status
个人娱乐项目,仅供学习交流使用 | 捐赠