提交记录 17904


用户 题目 状态 得分 用时 内存 语言 代码长度
Z_301 1007. 测测你的memset Compile Error 0 0 ns 0 KB C++11 318 B
提交时间 评测时间
2022-07-29 11:17:16 2022-07-29 11:17:17
#define For(i,l,r) for(int i=l,i##end=r;i<=i##end;++i)
#define rFor(i,r,l) for(int i=r,i##end=l;i>=i##end;--i)
void my_memset(char *a,char c,unsigned n) {
	typedef unsigned long long ull;
	ull x=0,*p=(ull*)(a);
	unsigned char d=c;
	For(i,0,7)*((char*)(&x)+i)=d;
	For(i,0,(n>>3)-1)*(p+i)=x;
	For(i,(n>>3)<<3,n)a[i]=c;
}

CompilationN/AN/ACompile ErrorScore: N/A


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