Answered step by step
Verified Expert Solution
Question
1 Approved Answer
please slove these in c++ Assignment 3.1 [15 points] Write an interactive program that computes the area of a square (area side2) or triangle (area
please slove these in c++
Assignment 3.1 [15 points] Write an interactive program that computes the area of a square (area side2) or triangle (area 1/2* base height) after prompting the user to type the first character of the figure name (t or s). Make sure that your output matches the sample output exactly. Note that a square does not have a base and a height. It has only a side. Your variable names should reflect this. Use double variables so that the user can enter a decimal if desired. Round your answer to the nearest tenth. Hint: in order to round the numbers to the nearest tenth, #includeStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started