Manuals/calci/INT

From ZCubes Wiki
Revision as of 21:50, 26 November 2013 by Swapna (talk | contribs)
Jump to navigation Jump to search

INT(number)

  • Where number is a number to be rounded.

INT() rounds a number down to the nearest integer.

Description

INT(number)

INT(3.6) is 3

  • TRUNC() and INT() functions are somewhat similar. TRUNC() removes the fractional part of the number, where as INT() rounds the number down to nearest integer.
  • INT() and TRUNC() work differently with negative numbers.

INT(-45.1) returns -45 whereas

TRUNC(-45.1) returns -46

  • If the input is non-numeric, Calci displays an error message.

Examples

Function Output
INT(1000.34) 1000
INT(23.4546) 23
INT(-3.25) -4
INT(-0.222) -1

See Also

References