Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I am having doubt in round() function. Please find the below results of round functions.
Round(8,6)=6
round(9,6)=12
round(10,6)=12
round(10,4)=12.
Could you please explain how round function works for the above results.
Thanks in advance.
Thanks and Regards,
Gayathri Devi
Gayathri,
Please find below information
Round() function returns rounding a number to the nearest multiple of step shifted by an offset number.
and if number to round is exactly middle, it is rounded upwards.
Round(8,6)=6 ............nearest multiple of 6 to 8 is 6
round(9,6)=12............nearest multiple of 6 to 9 is 6,12(Taken upwards)
round(10,6)=12..........nearest multiple of 6 to 10 is 12
round(10,4)=12..........nearest multiple of 4 to 10 is 8,12(Taken upwards)
You can also find examples here
Regards,
Nikita Deshwal
Gayathri,
Please find below information
Round() function returns rounding a number to the nearest multiple of step shifted by an offset number.
and if number to round is exactly middle, it is rounded upwards.
Round(8,6)=6 ............nearest multiple of 6 to 8 is 6
round(9,6)=12............nearest multiple of 6 to 9 is 6,12(Taken upwards)
round(10,6)=12..........nearest multiple of 6 to 10 is 12
round(10,4)=12..........nearest multiple of 4 to 10 is 8,12(Taken upwards)
You can also find examples here
Regards,
Nikita Deshwal
Thank you so much for reply Nikita. It was very useful.
Hi Nikita,
It would be very helpful if you explain Num() function also.
Please find the below results of NUM().
Num(11111.111,'#,##0',',',' ')=11111,110
Num(111.11,'# ##','.',' ')=1 11
Num(1.11,'# #0',',',' ')=1
Could you please explain how it works.
Thanks and Regards,
Gayathri