Question: Using DevC++ 2. (21 points) Right Triangle Analysis: Create a data file (using Notepad, perhaps) containing the values shown below (plus add 5 more lines
Using DevC++

2. (21 points) Right Triangle Analysis: Create a data file (using Notepad, perhaps) containing the values shown below (plus add 5 more lines of your choice) and then write a C++ program as follows . Read the data file. Assume that it has exactly 10 lines with 2 numbers per line. Side A values are in the left column and side B values are in the right column. the sides are valid. for all sides and 1 digit after the decimal point for all angles. The values should align with the headings. An . Calculate the hypotenuse, H, and the two angles, a and b (in degrees), shown in the diagram below. Assume that . Write the results to an output data file. The results should include headings and 2 digits after the decimal point example is shown below . Print the program and the two data files. Input data file 10 15 20 25 30 6 10 Sides A and B a right triangle 18 Pick values for 5 more valid triangles Output data file (heading plus values for 10 triangles) Side A 10.00 Side B 6.00 Side H Angle a (deg) 11.66 Angle b (deg) 31.0 59.0
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
