I'm trying to deal 13 cards to 4 players with a vector array and then show the hands. But I am struggling to figure out how to deal the cards. I know I have to use pop and push in the deck to deal the cards, but I can't get anything to work. Any ideas would be helpful. I tried this so far,
void deal(vector<int> deck, int card[][cards], int players) {
for (int i = 0; i < players; i++) {
cout << "Player " << i + 1 << ": ";
for (int k = 0; k < cards; k++) {
deck.push_back(cards);
}
cout << endl;
}
}