Difference between revisions of "Manuals/calci/INT"

From ZCubes Wiki
Jump to navigation Jump to search
 
(17 intermediate revisions by 4 users not shown)
Line 1: Line 1:
=INT(number)=
+
<div style="font-size:30px">'''INT(Number)'''</div><br/>
 
+
*<math>Number</math> is any real number.
*Where 'number' is a number to round.
+
**INT() rounds a number down to the nearest integer.
 
 
INT() rounds a number down to the nearest integer.
 
  
 
== Description ==
 
== Description ==
  
INT(number)
+
*This function gives number without any decimal part.
 +
*The function INT(Number) is rounding the given number to down to the nearest number.
 +
*Integer is the number without any decimal or fractional part but it can be the natural number with positive or negative sign. i.e.,INTEGER={….-3,-2,-1,0,1,2,3...}
 +
*So integers are countably infinite set.
 +
*In <math>INT(Number)</math>, where <math> Number </math> is any real number.Also <math> Number </math> can be any operations with the real numbers.
 +
*For e.g.,INT(2.3*4.7)
 +
*This function will give result as error when  <math> Number </math> is non numeric.
  
INT() function rounds a number to the nearest integer towards zero.
+
==ZOS==
 +
*The syntax is to calculate INT function in ZOS is <math>INT(Number)</math>.
 +
**<math>Number</math> is any real number.
 +
*For e.g.,INT(-10.5),INT((-19.25*11.21)/4)
 +
{{#ev:youtube|EVF31NEtqCM|280|center|Integer}}
  
For Example,
+
==Examples==
 +
#INT(10.99)=10
 +
#INT(-10.99)=-11
 +
#INT(0.05)=0,INT(-0.05)=-1
 +
#INT(4.56+7.21)=11
 +
#INT(10.78-9.45)=1
 +
#INT(12.76*12.76)=162
 +
#INT(49.54/20.4)=2
 +
#20.76-INT(19.45)=1.7600000000000016
  
INT(3.6) ''returns 3'' as output.
+
==Related Videos==
INT(-2.4) ''returns -3'' as output.
 
  
INT() can be used with multiple inputs as -
+
{{#ev:youtube|1XLjvkL2VZA|280|center|INT Function}}
 
 
INT(4.5,6.7,3.345,2) that ''displays 4,6,3,2 as a result''.
 
 
 
*If the input is non-numeric, Calci displays a #NaN error message.
 
 
 
*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''
 
 
 
== Examples ==
 
 
 
<div id="6SpaceContent" class="zcontent" align="left">
 
 
 
{| id="TABLE3" class="SpreadSheet blue"
 
|- class="even"
 
| class="  " | '''Function'''
 
| class="  " | '''Output'''
 
 
 
|- class="odd"
 
| class="sshl_f" |INT(1000.34)
 
| class="sshl_f" |1000
 
 
 
|- class="even"
 
| class="sshl_f" |INT(23.4546)
 
| class="sshl_f" |23
 
 
 
|- class="odd"
 
| class="sshl_f" |INT(-3.25)
 
| class="sshl_f" |-4
 
 
 
|- class="odd"
 
| class="sshl_f" |INT(-0.222)
 
| class="sshl_f" |-1
 
|}
 
  
 
== See Also ==
 
== See Also ==
Line 73: Line 51:
 
*[http://en.wikipedia.org/wiki/Integer Integer]
 
*[http://en.wikipedia.org/wiki/Integer Integer]
 
*[http://en.wikipedia.org/wiki/Rounding#Tie-breaking Rounding]
 
*[http://en.wikipedia.org/wiki/Rounding#Tie-breaking Rounding]
 +
 +
 +
 +
*[[Z_API_Functions | List of Main Z Functions]]
 +
 +
*[[ Z3 |  Z3 home ]]

Latest revision as of 04:29, 8 June 2020

INT(Number)


  • is any real number.
    • INT() rounds a number down to the nearest integer.

Description

  • This function gives number without any decimal part.
  • The function INT(Number) is rounding the given number to down to the nearest number.
  • Integer is the number without any decimal or fractional part but it can be the natural number with positive or negative sign. i.e.,INTEGER={….-3,-2,-1,0,1,2,3...}
  • So integers are countably infinite set.
  • In , where is any real number.Also can be any operations with the real numbers.
  • For e.g.,INT(2.3*4.7)
  • This function will give result as error when is non numeric.

ZOS

  • The syntax is to calculate INT function in ZOS is .
    • is any real number.
  • For e.g.,INT(-10.5),INT((-19.25*11.21)/4)
Integer

Examples

  1. INT(10.99)=10
  2. INT(-10.99)=-11
  3. INT(0.05)=0,INT(-0.05)=-1
  4. INT(4.56+7.21)=11
  5. INT(10.78-9.45)=1
  6. INT(12.76*12.76)=162
  7. INT(49.54/20.4)=2
  8. 20.76-INT(19.45)=1.7600000000000016

Related Videos

INT Function

See Also

References