提交记录 7801


用户 题目 状态 得分 用时 内存 语言 代码长度
JacaJava 1003. 测测你的二分查找 Accepted 100 327.35 us 12 KB C++ 181 B
提交时间 评测时间
2019-01-25 10:21:09 2020-08-01 01:08:37
int binary_search(const unsigned *a, int n, unsigned x)
{
	register int l,r,m;
	l=0; r=n;
	if(r>x+3) r=x+3;
	for(;l<r;){
		m=l+r>>1;
		if(a[m]<x) l=m+1;
		else r=m;
	}
	return l;
}

CompilationN/AN/ACompile OKScore: N/A

Testcase #1327.35 us12 KBAcceptedScore: 100


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