Int, Trunc, Round and Even function examples in taking an integer in Excel

Опубликовано: 16 Июнь 2024
на канале: Loinsure
98
1

There are five main types of functions that are used to take an integer in Excel, which are functions that do not round but only retained integer parts, rounding up functions, the functions that take an integer as the nearest even number, rounding up and rounding down functions.

Chapters:
0:00 Excel Int function examples
0:51 Excel Trunc function example
2:00 Excel Round function example
2:42 Excel Even function example

Description:

Int, Trunc, Round and Even function examples in taking an integer in Excel

The Int and Trunc functions only retain the integer part, the Round function rounde to, Even function roundes to the nearest even number, Round and Ceiling functions rounded up, RoundDown and Floor functions round down, parameters and usage methods are different for different functions.

One. The functions that only truncates the integer part

(1) Excel int function examples

1. Enter the formula =INT(A1) in cell B1, press Enter on the keyboard, then 85.68 in cell A1 becomes 85, change the value in A1 to -85.68, also use the formula =INT(A1), the result is -86, and then change the value in A1 to -85.25, also use the formula =INT(A1), the result is -86.

2. Note: When it is a positive number, the INT function is used to round up, and only the integer part is retained, and the decimal part is abandoned, and it is not rounded; When negative, carry forward regardless of whether a digit behind the decimal point is greater than or equal to 5.


(2) Excel trunc function example

1. Enter the formula =TRUNC(A1,0) in cell B1, press Enter on the keyboard, then 85.6 of cell A1 becomes 85, change 85.6 to -85.6, also use the formula =TRUNC(A1,0), the result is -85, and then change -85.6 to -85.2, the result is also -85.

2. Change the value of A1 to 85.2, enter the formula =TRUNC(A1,-1) in B1, press Enter on the keyboard, and the result is 80.

4. Note: In the formula =TRUNC(A1,0), 0 means that no decimal is retained; When rounded, the number behind the decimal point is greater than or equal to 5 does not carry forward; When the "number of digits specified" is less than 0, the right digit of the corresponding number of digits is replaced by 0, for example, 85.2 becomes 80 in the above example, and =TRUNC(85.6,-1), the result is also 80, -1 means that ten digits are taken, and the number of digits is replaced by 0.


Two. Excel round function example

1. Enter the formula =ROUND(A1,0) in cell B1, press Enter on the keyboard, then 85.54 of cell A1 becomes 86, and the result is rounded; Change the value of A1 to 85.4 and use the formula =ROUND(A1,0) to get 85 without rounding; Then change the value of cell A1 to -85.6, also using the formula =ROUND(A1,0), and the result is -86, which also carry forward.

2. Note: Rounded by the Round function, whether positive or negative, it will be rounded, and the 0 in the formula =ROUND(A1,0) means that no decimal is retained.


Three. Excel even function example

1. Enter the formula =EVEN(A1) in cell B1, press Enter on the keyboard, then 85.3 of cell A1 becomes 86, and 86 is an even number; Change 85.3 to -85.3 and use the formula =EVEN(A1) to get -86, which is also an even number.

2. Note: Using the Even function, it will be rounded to the nearest even number, regardless of whether it is positive or negative, and whether the number behind the decimal point is greater than or equal to 5. Another example is =EVEN(86.3), which results in 88, and only 88, an even number that is an integer, is closest to 86.3.


Смотрите видео Int, Trunc, Round and Even function examples in taking an integer in Excel онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Loinsure 16 Июнь 2024, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 98 раз и оно понравилось 1 людям.