November 2001
Beginner
1128 pages
29h 12m
English
| 1: | Consider the following class declaration:
class Cow {
char name[20];
char * hobby;
double weight;
public:
Cow();
Cow(const char * nm, const char * ho, double wt);
Cow(const Cow c&);
~Cow();
Cow & operator=(const Cow & c);
void ShowCow() const; // display all cow data
} ;
Provide the implementation for this class and write a short program that uses all the member functions. |
| 2: | Enhance the String class declaration (that is, upgrade string1.h to string2.h) by doing the following:
|
Read now
Unlock full access