Question: Design a C + + program that involves creating a class named 'Triangle. ' This class should encapsulate private attributes such as side 1 ,

Design a C++ program that involves creating a class named 'Triangle.' This class should encapsulate private attributes such as side1, side2, side3, height, perimeter, and area. Allocate one object using dynamic memory allocation within this class and calculate its area and perimeter. (At least you need to create six member functions including 4 mutators). add a comment ,make sure to only use #include and using namespace std;. dont add other #include or short cut codes as std:
This project should contain four files:
1) header file
2) a .cpp file to store the member functions definition of this class
3) main.cpp
4)README.txt to introduce and explain your project.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!