C++ Advanced · exercise 05
Architecture & interfaces
Drive two controller implementations through one abstract interface.
C++ Advanced lesson 05Guided steps
- 1.Give Controller a pure virtual command() and a virtual destructor.
- 2.Implement it twice and store both behind std::unique_ptr<Controller>.
- 3.Call each one through the base pointer only.
Your code
Your code is saved in this browser after every run and restored next time.