Return | Method | Summary |
---|---|---|
static double | cbrt(double a) | Returns the cube root. |
static double | sqrt(double a) | Returns the square root of a double value. |
public class Main {
public static void main(String[] args) {
System.out.println(Math.cbrt(2));
System.out.println(Math.sqrt(2));
}
}
The output:
1.2599210498948732
1.4142135623730951
java2s.com | Contact Us | Privacy Policy |
Copyright 2009 - 12 Demo Source and Support. All rights reserved. |
All other trademarks are property of their respective owners. |