Compiling it works. However, if I remove the /* and */ to add it to the code, it'll still compile, but the program will stop functioning. Windows gives me an error msg that cardDraw.exe has stopped working. Not sure what's going on here..
/* through */ is comment, which I guess you already know since you went through this code. Im not quite sure what you're asking though? The program doesn't work with it or without?
What it's supposed to do is output the value and suit 5 Cards objects in the array hand[]. If the object is a J, Q, K, or Ace it should output that instead of a number.
What happens is the program freezes, and Windows gives me an error (not the compiler).
You're trying to iterate through more cards than there actually are (numCards+1), so you shouldn't be surprised.
By the way, it would be better if you create a Deck class that internally uses a vector to store the cards.
vectors are a basic concept, so if they didn't appear in your book yet, you probably should be worried.
If they appear at all in the book, you might want to read that chapter first. vectors are basically dynamic arrays and are easy to use.