[Solved] Implement a class Person with two fields name and age, and a class Car with three fields [closed]

[ad_1]

To answer your specific question: You are not printing anything.

Add this to your code

for (vector<Car*>::const_iterator iter = cars.begin(); iter != cars.end(); ++iter)
    (*iter)->print();

[ad_2]

solved Implement a class Person with two fields name and age, and a class Car with three fields [closed]