问题
I am writing a formula in excel in which I am diving 2 numbers and I don't want value in decimal.
I tried using ROUND(5/10,0) but it round of 0.5 to 1.
But my requirement is (0-0.99) should be evaluated as 0.
Similarly (2-2.990 should be evaluated as 2.
E.g.
- (5/10) - 0 (output)
- (15/10) - 1 (output)
- (25/10) - 2 (output)
Thanks in Advance.
回答1:
You can use the function ROUNDDOWN
.
Example:
ROUNDDOWN(15/10,0)
The second parameter stands for the precision. Zero means that you won't have any decimal numbers.
回答2:
You can use INT
to find the next lower integer.
=INT(5/10)
gives0
=INT(15/10)
gives1
=INT(25/10)
gives2
=INT(-1/10)
gives-1
(because -1 is the integer which is lower than -0.1)=INT(-15/10)
gives-2
(for a similar reason)
回答3:
Use INT()
or FLOOR()
function to do that...
=INT(A1)
or
=FLOOR(A1,1)
If you want to use directly, then use as =INT(5/10)
or =INT(15/10)
...etc.
In case of =Floor()
function use as =FLOOR(5/10,1)
or =FLOOR(15/10,1)
... etc
来源:https://stackoverflow.com/questions/42130613/round-up-the-value-to-lowest-in-microsoft-excel