min

warning

This function starts with lowercase letter.

Description

Function used to compare the values.

NameDescription
aValue a to compare.
bValue b to compare.

Returns

Returns the smallest of a and b. If both are equivalent, a is returned.

Examples

//Since a is smaller than b so result will be 5.
public OnGameModeInit()
{
new a, b, result;
a = 5;
b = 10;
result = min(a,b);
printf ("min(a,b) =", param, result);
return 0;
}

Related Functions

  • min: Compare and get the minimum value .
  • max: Compare and get the maximum value .