System.Math.Min Method

Returns the smaller of two 16-bit unsigned integers.

Syntax

[System.CLSCompliant(false)]
[System.Runtime.ConstrainedExecution.ReliabilityContract(System.Runtime.ConstrainedExecution.Consistency.WillNotCorruptState, System.Runtime.ConstrainedExecution.Cer.Success)]
public static ushort Min (ushort val1, ushort val2)

Parameters

val1
The first of two 16-bit unsigned integers to compare.
val2
The second of two 16-bit unsigned integers to compare.

Returns

Parameter val1 or val2, whichever is smaller.

Remarks

This method is not CLS-compliant. For a CLS-compliant alternative, use Math.Min(sbyte, sbyte)(int, int).

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0