Hi All,
Can anybody clarify me what is the purpose of making pure virtual function as const.
Like
virtual double area() const = 0;
Thanks in advance.
Printable View
Hi All,
Can anybody clarify me what is the purpose of making pure virtual function as const.
Like
virtual double area() const = 0;
Thanks in advance.
The same reason as for any other function, the implementation to be shouldn't affect the state of the object.