Introduction
The Long.max()
method is used to return the numerically greater value (maximum value) of the two long numbers passed as arguments. It returns the positive value if one positive and one negative number is passed, and the value with lower magnitude if both the numbers passed are negative.