#include "Circle.h" #include "Rectangle.h" #include "Square.h" #include #include int main() { // Declarations Circle circle; Rectangle rectangle; Square square; // Obtain shape from user char answer; cout << "Is the room a circle, rectangle, or square (C/S/R)? "; cin >> answer; // Determine which object to use if (toupper(answer) == 'C') { circle.get_info(); cout << "Area = " << circle.area() << endl; cout << "Perimeter = " << circle.perimeter() << endl; } else if (toupper(answer) == 'R') { rectangle.get_info(); cout << "Area = " << rectangle.area() << endl; cout << "Perimeter = " << rectangle.perimeter() << endl; } else if (toupper(answer) == 'S') { square.get_info(); cout << "Area = " << square.area() << endl; cout << "Perimeter = " << square.perimeter() << endl; } else cout << "Bad shape." << endl; }