Answer:
The program to this question can be given as:
Program:
#include <stdio.h> //include header files
#include<math.h>
int main() //main method
{
double treeHeight = 0.0; //declare variables
and assign value
double shadowLength = 0.0;
double angleElevation = 0.11693706;
// (0.11693706 radians = 6.7 degrees) convert number into angle.
shadowLength = 17.5;
treeHeight = shadowLength * tan(angleElevation); //convert number into angle
printf("Tree height: %lf\n", treeHeight); //print value.
return 0;
}
Output:
Tree height: 2.055778
Explanation:
In the above C language program firstly we include the headers. In this header file, we include a (math.h) header file this file helps to use the math function. Then we declare the main method in the main method we declare the variable that is given in the question that are treeHeight, shadowLength , angleElevation. All the variable datatype is double because it stores the floating-point value. Then we apply the formula that is treeHeight = shadowLength * tan(angleElevation). In this formula, the treeHeight variable holds the value. Then we print the variable value for print the double value we use the lf(that is long float).