ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   what does the +1 do in =INT(6*A2)+1? (https://www.excelbanter.com/excel-worksheet-functions/111717-what-does-1-do-%3Dint-6%2Aa2-1-a.html)

Chantel

what does the +1 do in =INT(6*A2)+1?
 
i need to know the purpose of the +1.

Marcelo

what does the +1 do in =INT(6*A2)+1?
 
Hi Chantel,

it should be to round up eg.

if you have 1.34 on A2 it will return 9

because 1.34*6 = 8.04
int(8.04) = 8
8+1=9

hth
--
regards from Brazil
Thanks in advance for your feedback.
Marcelo



"chantel" escreveu:

i need to know the purpose of the +1.


Teethless mama

what does the +1 do in =INT(6*A2)+1?
 
Let's say A2=2.125
A3 =INT(6*A2) The result will be 12. When you add 1, the result will be 13

"chantel" wrote:

i need to know the purpose of the +1.


Ken Hudson

what does the +1 do in =INT(6*A2)+1?
 
Hi,
Looks to me like it does the same thing as the ROUNDUP function.
The INT function returns the integer part of 6*A2 and then 1 is added to it.
=ROUNDUP(6*A2) would yield the same result.
--
Ken Hudson


"chantel" wrote:

i need to know the purpose of the +1.



All times are GMT +1. The time now is 01:11 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com