// inherit9.h By: Aiman Hanna - ©1993-2002 Aiman Hanna #ifndef INHERIT9_H #define INHERIT9_H #include enum avl_colors { red, black, white, green }; enum yes_no { yes, no }; class Vehicle { public: Vehicle( void ); Vehicle( avl_colors, int ); // Step #5 : Declare the function as virtual in the abstract class. virtual void ShowInfo( void ); int GetNumCyl( void ); char* GetColor( void ); private: int numcyl; avl_colors color; }; class Bus: public Vehicle { public: Bus( avl_colors aclr = black , int cyl = 12, yes_no bar = no ); void ShowInfo( void ); yes_no HasBar ( void ); private: yes_no barexist; }; class Van: public Bus { public: Van( avl_colors aclr = white , int cyl = 6, yes_no tur = no ); void ShowInfo( void ); yes_no IsTurbo( void ); private: yes_no turbo; }; #endif