Max
Moduł: Math
function Max(A,B: Integer): Integer; overload;
function Max(A,B: Int64): Int64; overload;
function Max(A,B: Single): Single; overload;
function Max(A,B: Double): Double; overload;
function Max(A,B: Extended): Extended; overload;
Przeciążona funkcja porównuje wartości dwóch parametrów: A i B, oraz zwraca ten, który jest większy:
program Foo;
{$APPTYPE CONSOLE}
uses
Math;
begin
Writeln('Max(50, 51): ', Max(50, 51)); // wyświetli 51
Readln;
end.
Zobacz też: