mirror of
https://github.com/pjreddie/darknet.git
synced 2023-08-10 21:13:14 +03:00
some more stuff
This commit is contained in:
@ -521,6 +521,11 @@ int max_index(float *a, int n)
|
||||
|
||||
int rand_int(int min, int max)
|
||||
{
|
||||
if (max < min){
|
||||
int s = min;
|
||||
min = max;
|
||||
max = s;
|
||||
}
|
||||
int r = (rand()%(max - min + 1)) + min;
|
||||
return r;
|
||||
}
|
||||
|
Reference in New Issue
Block a user