Ask Question
6 April, 21:24

Write a statement that assigns treeHeight with the height of a tree given the distance from the tree (in feet) and angle of elevation (in degrees).

Use the following formula: tangent of angleElevation treeHeight / treeDistance treeHeight

+4
Answers (1)
  1. 7 April, 00:24
    0
    treeHeight = tangent of angleElevation * treeDistance

    In java, we could write it as:

    double treeHeight = (Math. tan (angleElevation) * treeDistance);

    Math. tan (angleElevation) is an inbuilt java mathematical function used to calculate the tangent of a value and the return value is always double.

    Explanation:

    formula:

    tangent of angleElevation = treeHeight/treeDistance

    We want to assign treeHeight, so we cross-multiply and we get:

    treeHeight = tangent of angleElevation * treeDistance

    Off course, the treeHeight will be in feet also.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “Write a statement that assigns treeHeight with the height of a tree given the distance from the tree (in feet) and angle of elevation (in ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers