In C++ 2.12 LAB: Hypotenuse Given two numbers that represent the lengths of a right triangle's legs (sides adjacent to the right angle), output the length of the third side (i.e. hypotenuse) with two...


In C++



2.12 LAB: Hypotenuse






Given two numbers that represent the lengths of a right triangle's legs (sides adjacent to the right angle), output the length of the third side (i.e. hypotenuse) with two digits after the decimal point.


Output each floating-point value with two digits after the decimal point, which can be achieved by executing
cout < fixed="">< setprecision(2);="" once="" before="" all="" other="" cout="">


Ex: If the input is:


3.0 4.0

the output is:


Hypotenuse: 5.00



Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here