Replies: 7 comments
-
|
您好,该功能可以通过用户自行利用cyrand函数存储在数组中,不断检测是否重复,否则删除的方式做成。 如果您急需此功能,您还得自行制作,如果您能等到周四上线,那么谢谢您的支持! |
Beta Was this translation helpful? Give feedback.
-
|
|
Beta Was this translation helpful? Give feedback.
-
|
感谢! |
Beta Was this translation helpful? Give feedback.
-
|
您好,功能已被实现,稍后更新。 代码如下: inline bool checktmp(int *arr,int tmp,int flag,int end){
if(flag==0){
return true;
}
for(int i=0;i<end;i++){
else if(flag==-1){
if(arr[i]==tmp){
return false;
}
}
else if(flag==1){
if(arr[i]>tmp){
return false;
}
}
else if(flag==2){
if(arr[i]<tmp){
return false;
}
}
}
return true;
}
inline void randomArr(int* arr,int n,int lower,int upper,int flag){
for(int i=0;i<n;){
int tmp=cyrand(lower,upper);
if(checktmp(arr,tmp,flag,i-1)){
arr[i++]=tmp;
}
}
}
|
Beta Was this translation helpful? Give feedback.
-
|
感谢! |
Beta Was this translation helpful? Give feedback.
-
|
您好,新功能使用如何。如果没有其他问题,9:30将关闭这个 Issue |
Beta Was this translation helpful? Give feedback.
-
|
很好,我现在就关闭了 |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
在 Wiki 中未找到以下功能,希望能添加。如果项目中本来就有以下功能,请告知使用方法,谢谢。
支持你们的项目,加油!
Beta Was this translation helpful? Give feedback.
All reactions