| [Overview][Constants][Types][Classes][Procedures and functions][Index] | 
Return one of two values, depending on a boolean condition
Source position: math.pp line 580
| function ifthen( | 
| val: Boolean; | 
| const iftrue: Integer; | 
| const iffalse: Integer = 0 | 
| ):Integer; overload; | 
| val: Boolean; | 
| const iftrue: Int64; | 
| const iffalse: Int64 = 0 | 
| ):Int64; overload; | 
| val: Boolean; | 
| const iftrue: Double; | 
| const iffalse: Double = 0.0 | 
| ):Double; overload; | 
ifthen returns iftrue if val is True, and iffalse if val is False.
This function can be used in expressions.