Java StrictMath.max(double a, double b)
Syntax
StrictMath.max(double a, double b) has the following syntax.
public static double max(double a, double b)
Example
In the following code shows how to use StrictMath.max(double a, double b) method.
/*w w w. ja v a2 s . co m*/
public class Main {
public static void main(String[] args) {
double d1 = 12 , d2 = 34, d3 = -56;
System.out.println(StrictMath.max(d1, d2) );
System.out.println(StrictMath.max(d1, d3));
}
}
The code above generates the following result.