#include #include #include "main.h" int main() { auto c1 = std::make_shared(3.0); auto c2 = std::make_shared(5.0); auto c3 = std::make_shared(7.0); c1->set_next(c2.get()); c2->set_next(c3.get()); std::cout << "Forward:\n"; for (auto& shape : c1->traverse()) { shape.draw(); } std::cout << "\nBackward:\n"; for (auto& shape : c1->traverse()) { shape.draw(); } }