Problem Statement - 02C
Write the definition of a class RING in C++ with following description: Private Members - RingNumber // data member of integer type - Radius // data member of float type - Area // data member of float type - CalcArea() // Member function to calculate and assign // Area as 3.14 * Radius*Radius Public Members - GetArea() // A function to allow user to enter values of // RingNumber and Radius. Also, this // function should call CalcArea() to calculate // Area - ShowArea() // A function to display RingNumber, Radius // and Area
Solution
CSKC| Created: 8-Jan-2019 | Updated: 14-Jan-2019|CBSE12D-2017