I\'m using the random_shuffle on a vector like this:
random_shuffle
#include vector deck; //some code to add cards to the deck h
Place the line:
srand (time (0));
in your code before you do anything else, such as at the start of main().
main()
Without that, the default seed of 1 will always be used, leading to identical sequences from rand() and anything that uses it.
rand()