Module 2. Class Member Functions Exercise Answers

1.
   // -------- member function to return the day the animal was last
   // -------- weighed
   inline int ZooAnimal::reptWeightDate ()
   {
    return weightDate;
   }


2.
      inline void changeWeightDate (int today) {weightDate = today;};


3.
   // -------- member function to create a pointer from object critter
   // -------- to its mother
   void ZooAnimal::isMotherOf (ZooAnimal& critter)
   {
    critter.mother = this;
   }