What is the output of the function main of Exercise 34, if the definition of small is replaced by the following definition: (13)
class small
public: virtual void print() const;
virtual int add()
return x + y;
small()
small(int a, int b)
x = a;
y = b;
private:
int x = 0;
int y = 0;
;
What is the difference between compile-time binding and run-time binding? (12)
Is it legal to have an abstract class with all member functions pure virtual? (14)