So I am making an array of 52 ints, I add in random numbers and make sure there all different. If there is a duplicate I would generate a new number so that current index that am at is different. Where am I going wrong?
for(i=0; i < SIZE; i++){
deck[i] = (rand() % 52);
for(c= 0; c <= i; c++ ){
if(deck[c] == deck[i+1]){
deck[i] = (rand() % 52);
}
}
}