In: Computer Science
#include <stdio.h>
#include <math.h>
int main()
{
//variable declaration
long int k;
long double h,n, result;
//input constant value
printf("Enter the constant value(h): ");
scanf("%Lf", &h);
//input total number of student
printf("Enter the number of students(k): ");
scanf("%ld", &k);
//input mid point value
printf("Enter the midpoint value(n): ");
scanf("%Lf", &n);
//calculate the expression value
result = h / (k * sqrt(n));
//display result
printf("\nResult = %Lf", result);
return 0;
}
INPUT:
Enter the constant value(h): 999999999
Enter the number of students(k): 1000000000
Enter the midpoint value(n): 10
OUTPUT:
Result = 0.316228