Returns the lesser of the two given values.
- Xcode 9.0+
- Swift Standard Library
A floating-point value.
Another floating-point value.
The minimum of
y, or whichever is a number if the other is NaN.
This method returns the minimum of two values, preserving order and eliminating NaN when possible. For two values
y, the result of
minimum(x, y) is
x <= y,
y < x, or whichever of
y is a number if the other is a quiet NaN. If both
y are NaN, or either
y is a signaling NaN, the result is NaN.
minimum method implements the
min operation defined by the IEEE 754 specification.