Ask Question

4. (Hypotenuse Calculations) Define a function called hypotenuse that calculates the length of the hypotenuse of a right triangle when the other two sides are given. The function should take two arguments of type double and return the hypotenuse as a double. Test your program with the side values specified in Fig

+3
Answers (1)
  1. 7 October, 16:09
    0
    Hypotenuse = sqrt (a^2 + b^2)

    A program in C:

    double hypotenuse (int a, int b) {

    return sqrt (pow (a, 2) + pow (b, 2));

    }
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “4. (Hypotenuse Calculations) Define a function called hypotenuse that calculates the length of the hypotenuse of a right triangle when the ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers