hello,
i have a problem with a vector of pointers.
i want to use push_back, and im doing it like this:
vector<Computer*> vcomputer;
Computer *check=new Mac(id,cpu,hdd,ram,monitor,all_in_one,sound,lan,dv d);
vcomputer.push_back(check);
(Computer is my perent class, and mac inherit from him).
what is the right way to do it?
thank you!