| 19 | virtual double volume() const { return m_length * m_width * m_height; } |
| 20 | |
| 21 | void showVolume() const |
| 22 | { |
| 23 | std::cout << "The volume from inside Box::showVolume() is " |
| 24 | << volume() << std::endl; |
| 25 | } |
| 26 | |
| 27 | private: |
| 28 | double m_length, m_width, m_height; |