Figure 17.1 Class Description for Apple
// class Apple// created 1987 by Standard Apple of Ohioclass Apple { public: // constructors Apple () : variety("generic") { } Apple (string & v) : variety (v) { } Apple (const Apple & r) : variety (r.variety) { } // apple operations ostream & printOn (ostream & out) { return out << "Apple: " << variety; } private: string variety;};