Java tutorial
public class Main { public static void main(String[] args) { double d1 = 0.90, d2 = 5.00; System.out.println("arc cosine value of " + d1 + " = " + StrictMath.acos(d1)); // returns NaN if argument is NaN or its absolute value is greater than 1 System.out.println("arc cosine value of " + d2 + " = " + StrictMath.acos(d2)); } }