Question: Modify problem 1 so that it runs within a loop that prompts the user whether to continue at the end of each iteration and does
Modify problem 1 so that it runs within a loop that prompts the user whether to continue at the end of each iteration and does another if the user enters y or Y. (Sample run below)
$ ./HW02_06.exe
Enter the first angle (in degrees):
45
Enter the second angle (in degrees):
60
The cosine of 45.0000000 degrees is 0.707106769
Do another (y/n) ?
y
Enter the first angle (in degrees):
60
Enter the second angle (in degrees):
90
The cosine of 60.0000000 degrees is 0.499999970 Do another (y/n) ?
Y
Enter the first angle (in degrees):
30
Enter the second angle (in degrees):
-30
The cosine values of 30.0000000 degrees and -30.0000000 degrees are 0.866025448
Do another (y/n) ?
N
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
