Employee & Manager Class Hierarchy
In this exercise you'll implement 6 key methods in a C++ Employee/Manager class hierarchy. The rest of the code is already written for you.
Employee::toString() is virtual, Manager overrides it
Manager IS-A Employee — use Employee* to point to Managers
operator== compares employees by ID
Click each step in the left sidebar. It will open the right file and scroll to the TODO you need to implement.
Each TODO has detailed comments explaining what to implement, with examples of expected input/output.
Replace the placeholder (e.g., return false;) with your implementation. The code already compiles — you just need to make it correct.
Run compiles and executes your code. Check runs 14 automated tests to verify your implementation.
After implementing each TODO, you'll be asked to predict the output before running. A mini-lesson explains the polymorphism concept.
Stuck? Click the Hint button on any step for progressive help — nudge first, then approach, then code example.
Files marked with a lock icon are pre-written for you. You can read them but not edit — focus on the TODO files.
Your code is automatically saved in your browser. You can also Export/Import as a zip file.
What will this code output?