#include <string>
using std::string;
using std::ostream;

class Person{
  protected:
     string name;
     bool isMale;

  public:
     Person (string n, bool is);
     // In C++, methods that can be overriden must be declared "virtual"
     virtual string toString () const;

     // If a class has any virtual methods, it must have a virtual destructor
     virtual ~Person() {}

     // Since friend functions are not part of the class, they cannot
     //    be overriden. Instead, override a method this function calls.
     friend ostream &operator<< (ostream &out, const Person &person);
};
