Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Hello, I received your answers to my programming problem but I am brand new to P

ID: 3636863 • Letter: H

Question

Hello,

I received your answers to my programming problem but I am brand new to Programming and I do not understand what each line of code does or means. If I had a Step by step explanation of each line of code telling me what it means this would help me to understand the language quicker. I would also like to have an algorithym for this problem. This is the program:
Write a program that displays the following menu:
Geometry Calculator
1. Calculate the Area of a Circle
2. Calculate the Area of a Rectangle
3. Calculate the Area of a Triangle
4. Quit
Enter your choice (1-4)
If the user enter 1, the program should ask for the radius of the circle and then display its area. Use the following formula to calculate the circle's area:
area = pi*r^2
Use 3.1459for pi and the radius of the circle for r.

If the user enters 2, the program should ask for the length and width of the rectangle and then display the rectangle's area. Use the following formula to calculate the rectangle's area:
area = length x width

If the user enters 3, the program should ask for the length of the triangle's base and its height, and then display its area. Use the following formula to calculate the area of a triangle:
area = base x height x .5

If the user enter 4, the program should end.

Explanation / Answer

#include using namespace std; // library which has cout n cin int main() { int choice =0, over =0; // Defining variables cout
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote