computer programming 2 ....
Description
- The java.lang.Math.min(int a, int b)
- returns the smaller of two int values. That is, the result is the value closer to negative infinity. If the arguments have the same value, the result is that same value.
- If either value is NaN, then the result is NaN. Unlike the numerical comparison operators, this method considers negative zero to be strictly smaller than positive zero. If one argument is positive zero and the other is negative zero, the result is negative zero
Example
Thank you for
attention
Muneera Alajlan
How does the method work ?
write a program to use methods and show output.
Method min()