note Help Needed
This wiki is the result of an ongoing community effort — thank you all for helping!
If you want to provide changes to this page then please click here.
min
warning
This function starts with a lowercase letter.
Description
Function used to compare the values.
Name | Description |
---|---|
value1 | Value 1 (a) to compare. |
value1 | Value 2 (b) to compare. |
Returns
The lower value of value1
and value2
If both are equivalent, value1
is returned.
Examples
public OnGameModeInit()
{
new a, b, result;
a = 5;
b = 10;
result = min(a, b);
printf("min(%d, %d) = %d", a, b, result);
// Since a is smaller than b so result will be 5.
return 1;
}
Related Functions
- max: Compare and get the maximum value.