Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Turbo Pascal - <b> int return integer part of number pp 140</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 INT                    Return Integer Part of Number                 pp 140

 Syntax:  Int (NumVar) ;

 Type:    Real

 Form:    Function

 Purpose: Returns the greatest integer part of NumVar which is greater than
          or equal to NumVar, if NumVar > 0.  If NumVar < 0 then the smallest
          integer greater than or equal to NumVar is returned..

 Notes:   NumVar may be either Integer or Real.


 ----------------------------------------------------------------------------


 Usage:
       VAR
          IntVar  : Integer        ;
          RealVar : Real           ;
          Result  : Real           ;

       BEGIN
          Result  := Int (IntVar)  ;
          Result  := Int (RealVar) ;
       END.

See Also: Frac Round Trunc

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson