www.delorie.com/gnu/docs/gcc/g77_223.html   search  
 
Buy the book!


Using and Porting GNU Fortran

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

8.11.9.148 Int Intrinsic

 
Int(A)

Int: INTEGER(KIND=1) function.

A: INTEGER, REAL, or COMPLEX; scalar; INTENT(IN).

Intrinsic groups: (standard FORTRAN 77).

Description:

Returns A with the fractional portion of its magnitude truncated and its sign preserved, converted to type INTEGER(KIND=1).

If A is type COMPLEX, its real part is truncated and converted, and its imaginary part is disregarded.

See section 8.11.9.198 NInt Intrinsic, for how to convert, rounded to nearest whole number.

See section 8.11.9.9 AInt Intrinsic, for how to truncate to whole number without converting.


  webmaster     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003