Error: vector does not name a type

I’m having lots of errors in my final project (a poker and black jack sim). I’m using a vector to implement the “hands” in the blackJack class, and I’m using a structured data type declared in another class, which is publicly inherited. The error I’m worried about is the compiler I’m using telling me that I’m not declaring a type in the vector.

blackJack header file:

 #ifndef BLACKJACK_H
 #define BLACKJACK_H
 #include <vector>
 #include "card.h"

 class blackJack: public cards
    vector <Acard> playerHand;
    vector <Acard> dealerHand;

    void dealHands();
    void hitOrStay();
    void dealerHit();
    int handleReward(int);
    void printHands();

card header file (this is the class black jack inherits from):

 #ifndef CARD_H
 #define CARD_H

 const char club[] = "\xe2\x99\xa3";
 const char heart[] = "\xe2\x99\xa5";
 const char spade[] = "\xe2\x99\xa0";
 const char diamond[] = "\xe2\x99\xa6";
 //structured data to hold card information
 // a number, representing Ace-King (aces low)
 //a character, representing the card's suit
 struct Acard
   int number;
   char pic[4];

 // a class to hold information regarding a deck of cards
 //An array of 52 Acard datatypes, representing our Deck
 //an index to the next card in the array
 //a constructor initializing the array indices to Ace-king in each suit
 //a function using random numbers to shuffle our deck of cards
 //13 void functions to print each card
 class cards
    Acard Deck[52];
    int NextCard;
    Acard getCard();
    void shuffleDeck();

Leave a Comment