<-- Previous || Up || Next -->

Int Real Function
Math Reals Class

Public Function IntReal( _
    ByVal vX As Variant _
    ) As Variant

Floor of a real number.
Return the largest integer less than or equal to vX.

Examples:
    IntReal(2.4) = 2
    IntReal(2) = 2
    IntReal(.6) = 0
    IntReal(0) = 0
    IntReal(-.6) = -1
    IntReal(-2) = -2
    IntReal(-2.4) = -3
See also:
    IntRealVerify Subroutine
    Floor Function
    Int Function (Visual Basic)
Note: The Floor function is a more generalized version of IntReal.

vX: The real number that is to be rounded-down to the nearest integer. Function returns Null if vX is Null or cannot be fixed up to a number.
Note: This function is similar to the Visual Basic Int function, except that this one supports three-valued logic.

Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.