Java Cube Root Of Number
Chapter:
Math Class
Last Updated:
10-03-2017 14:51:11 UTC
Program:
/* ............... START ............... */
public class JavaCubeRoot {
public static void main(String[] args) {
Double d1 = 74.00;
Double d2 = 67.00;
System.out.println("Square root of " + d1 + " is " + Math.cbrt(d1));
System.out.println("Square root of " + d2 + "is " + Math.cbrt(d2));
}
}
/* ............... END ............... */
Output
Square root of 74.0 is 4.198336453808408
Square root of 67.0is 4.0615481004456795
Tags
Cube Root Of Number, Java, Math