What is a pure virtual function?
A9. “A pure virtual function is a function declared in a base class that has no definition relative to the base.” Q10. What is an abstract base class? A10. It is a class that has one or more pure virtual functions. Q11. What is the difference between MyClass p; and MyClass p();? A11. MyClass p; creates an instance of class MyClass by calling a constructor for MyClass. MyClass p(); declares function p which takes no parameters and returns an object of class MyClass by value. Q12. How do you know that your class needs a virtual destructor? A12. If your class has at least one virtual function, you should make a destructor for this class virtual. This will allow you to delete a dynamic object through a pointer to a base class object. If the destructor is non-virtual, then wrong destructor will be invoked during deletion of the dynamic object. Q13. Why were the templates introduced? A13. Many data structures and algorithms can be defined independently of the type of data they work with. You