next up previous contents index
Next: IOresult Up: Functions and Procedures Previous: Insert

Int

   

Declaration:

Function Int (X : real) : Real;

Description:

Int returns the integer part of any real X, as a real.

Errors:

None.

See also:

Frac, Round

Example
Program Example34;

{ Program to demonstrate the Int function. }

begin
  Writeln (Int(123.456):0:1);  { Prints  123.0 }
  Writeln (Int(-123.456):0:1); { Prints -123.0 }
end.



Michael Van Canneyt
Thu Sep 10 14:02:43 CEST 1998