Hey everyone, I am having trouble with a program dealing with Poker hands. I used 2 separate Classes, Card and friend class Hand(containing 5 cards), with the aim of setting 5 card hand using the input from the user. I wrote the set() functions for Card no problem. However I cannot get the coding for set() for class Hand right no matter what I tried.
Anyway this is the relevant code I have done so far,
int main()
{
int suit1, suit2, suit3, suit4, suit5;
int face1, face2, face3, face4, face5;
cout << "Enter a hand (10 integers): " << flush;
cin >> suit1 >> face1 >> suit2 >> face2 >> suit3 >> face3 >> suit4 >> face4 >> suit5 >> face5;
Card newCard1, newCard2, newCard3, newCard4, newCard5;
Hand newHand;
newHand.set(newCard1, newCard2, newCard3, newCard4, newCard5);
Does the error come from the implementation of the void Hand::set function? Or is there something wrong with the way I am calling it in the main? Any hints or help would be greatly appreiciated!!
can u please answer this?
print a list of integers from 1 to N that are both divisible by 2 and 3. after producing a list count the number of integers found.
thank you !