Question: * In C# programming * Create a program named CalArea that calculates and displays the area of a circle / rectangle / triangle . The

*In C# programming*
Create a program named CalArea that calculates and displays the area of a circle/rectangle/triangle.
The program Main () should have a prompt for choosing the area to calculate. There are three choices: circle, rectangle, and triangle. Upon choice, the Main() should further prompt for inputs for parameters. For a circle, only radius is needed; for rectangle, both length and width are needed; for triangle, three sides are needed. Once parameters are entered, the Main() should call the corresponding overloaded methods named DisplayArea() for the chosen shape The three overloaded methods should have the same names but different numbers of parameters, and should calculate and display the areas of the corresponding shapes. The formula for the area of a triangle with three sides (a,b, and c is given by A=s**(s-a)**(s-b)**(s-c)2, where s=a+b+c2. A sample output is shown below. Submit the cs file as an attachment.Note: the program assumes: 1) all parameters are positive, and 2) in the case of a triangle, two sides are greater than the other one. If your program can further validate the the two assumptions and correct invalid inputs until valid parameters are entered, as much as 5 bonus points will be given.
* In C# programming * Create a program named

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 Programming Questions!