I have a list of integers intList = {1, 3. 5. 2} (Its just an example integer and size both are unknown). I have to chose a random number from that list.
RandomInt = rand() % intList.size() 
will work in a similar way as RandomInt = rand() % 4 
and generate a randon number between 1 to 4. while intList is different.
If I am using RandomInt = std::random_shuffle = (intList, intList.size())
still getting error. I do not know how chose a random number from a list.
 
     
     
     
     
     
    