MAX

Previous  Next

 

max = MAX( value_1 AS REAL|INTEGER|STRING,

           value_2 AS REAL|INTEGER|STRING ) AS REAL|INTEGER|STRING

 

max = MAX( INTEGER|REAL ) AS INTEGER|REAL

 


 

Returns the larger of two values.  The argments can be of either REAL, INTEGER or STRING.  When using strings, both arguments must be of type STRING.  The second syntax will return the maximum real or integer value that MyBASIC2 can handle.

 

Example:

 

PRINT "["; MIN( 1, 2 );",";MAX( 1, 2 );"]"

[1,2]