Try the following:
DeckOfCards::DeckOfCards()
:suit{ "Hearts", "Diamonds", "Clubs", "Spades" }
{}
If this does not work, your compiler does not yet support this C ++ function. So you need to do it the old way:
DeckOfCards::DeckOfCards()
{
suit[0] = "Hearts";
suit[1] = "Diamonds";
suit[2] = "Clubs";
suit[3] = "Spades";
}
If you are going to use char pointers like this, you should make them const, i.e.:
const char *suit[ 4 ];
, . const, , , . std::string.