#include<bits/stdc++.h>
using namespace std;
int n=50, m=5;
string rs(){
int iRange1 = 0xf7 - 0xb0;
int iRange2 = 0xfe - 0xa1;
char cnStr[255] = {0};
cnStr[0]=rand()%iRange1 + 0xb0;
cnStr[1]=rand()%iRange2 + 0xa1;
return cnStr;
}
int main(){
srand((unsigned)time(NULL));
for(int i = 1; i <= n; i++){
for(int j = 1; j <= m; j++){
int r=rand()%4+1;
if(r==1){
cout<<(char)('a'+rand()%26);
}else if(r==2){
cout<<(char)('A'+rand()%26);
}else if(r==3){
cout<<(char)('0'+rand()%9);
}else{
cout<<rs();
}
}
cout<<'\n';
}
}名字生成器
这是 2026年2月8日 存档的第 1 版,不是当前版本。查看当前版本