Home  |  Delphi .net Home  |  System.Math  |  Max Method
  
Max  
Method  
Returns the largest of the two given numbers
Math Class
System NameSpace
CF1.  Function Max ( ValueA : Byte; ValueB : Byte ) : Byte; Static;
CF2.  Function Max ( ValueA : SByte; ValueB : SByte ) : SByte; Static;
CF3.  Function Max ( ValueA : SmallInt; ValueB : SmallInt ) : SmallInt; Static;
CF4.  Function Max ( ValueA : ShortInt; ValueB : ShortInt ) : ShortInt; Static;
CF5.  Function Max ( ValueA : Integer; ValueB : Integer ) : Integer; Static;
CF6.  Function Max ( ValueA : Int64; ValueB : Int64 ) : Int64; Static;
CF7.  Function Max ( ValueA : UInt64; ValueB : UInt64 ) : UInt64; Static;
CF8.  Function Max ( ValueA : Cardinal; ValueB : Cardinal ) : Cardinal; Static;
CF9.  Function Max ( ValueA : Decimal; ValueB : Decimal ) : Decimal; Static;
CF10.  Function Max ( ValueA : Single; ValueB : Single ) : Single; Static;
CF11.  Function Max ( ValueA : Double; ValueB : Double ) : Double; Static;
CF12.  Function Max ( ValueA : Word; ValueB : Word ) : Word; Static;
CF : Methods with this mark are Compact Framework Compatible
Description
Returns the largest of ValueA and ValueB numbers.
Notes
Static methods are not methods of an object - they are simply class functions or procedures available at any time.
Microsoft MSDN Links
System
System.Math
 Author links

 Buy Website Traffic at
 Buywebsitetrafficexperts.com

 Buy Proxies at
 Buyproxies.io
 
 
 
A simple example
program Project1;
{$APPTYPE CONSOLE}

var
  result : Integer;
begin
  result := System.Math.Max(1, 2);
  Console.WriteLine('Max(1, 2) = {0}', result.ToString);

  Console.ReadLine;
end.
   Max(1, 2) = 2
 
 
Delphi Programming Neil Moffatt 2002 - 2017. All rights reserved.  |  Contact the author