VS:Max
.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix
Description
Returns the maximum of the two numbers.
FUNCTION Max(
val1 :REAL;
val2 :REAL) :REAL;
def vs.Max(val1, val2): return REAL
Parameters
val1 REAL val2 REAL
Example
PROCEDURE Example; VAR a, b, c : REAL; BEGIN a := RealDialog('Enter one real number:', '0'); b := RealDialog('Enter another real number:', '0'); c := Max(a, b); AlrtDialog(Concat('Max(', a, ', ', b, ')=', c)); END; RUN(Example);
Version
Availability: from All Versions
This is drop-in function.