math.mMax() function

The math.mMax() function returns the larger of x or y.

*Output data type: Float*

  1. import "math"
  2. math.mMax(x: 1.23, y: 4.56)
  3. // Returns 4.56

Parameters

x

The X value used in the operation.

*Data type: Float*

y

The Y value used in the operation.

*Data type: Float*

Special cases

  1. math.mMax(x:x, y:+Inf) // Returns +Inf
  2. math.mMax(x: +Inf, y:y) // Returns +Inf
  3. math.mMax(x:x, y: NaN) // Returns NaN
  4. math.mMax(x: NaN, y:y) // Returns NaN
  5. math.mMax(x: +0, y: ±0) // Returns +0
  6. math.mMax(x: ±0, y: +0) // Returns +0
  7. math.mMax(x: -0, y: -0) // Returns -0