Finding Inverse Cosine in Radians
java
Solution
ans = Math.acos(invCosineVal)
There you go, 180/Math.PI converts it to degrees
Problem
This gives me the answer in degrees but I want the answer in Radians for Inverse Cosine. For example if I pick 0.5 for invCosineVal it will return 60 deg but not sure how I can find the answer in Radians which should be 1.047. ``` ans = Math.acos(invCosineVal) * (180/Math.PI); ```