i'm attempting to run a million simulations of a card game to return a percentage "casino house edge."
my understanding of the rand() function is not clear enough to know whether this will generate a new shuffle every time or if it has a limit. in other words, at some point into the million games, will the same patterns of shuffles emerge?
srand(time(NULL));
for (int games=0;games<iGames;games++){
///shuffle///
for (int i=0; i<(iUserDeckSize-1); i++) {
int r = i + (rand() % (iUserDeckSize-i)); // Random remaining position.
card temp = cards[i]; cards[i] = cards[r]; cards[r] = temp;
}
// rest of card game code goes here
}