Cloud Altitude Measurement Problem 172

Back to General discussions forum

yuyuyuyuyuyuyuyuyuyuyuyu     2020-06-21 18:29:09

What is wrong in this code

  double d1 = in.nextDouble(); 
  double tanA = in.nextDouble();
  tanA = Math.tan(tanA);
  double tanB = in.nextDouble();
  tanB = Math.tan(tanB);
  System.out.print(Math.round((tanA*d1*tanB)/(tanB-tanA))+" ");?
Hyuto     2020-06-22 02:15:38
User avatar

I think you must change it to radian first before calculating tan.

Please login and solve 5 problems to be able to post at forum