# Greater than,Less than under IF and AND Function

My problem :
Let, Cell K3 contains a number : 568124
Now, if the right most digit is <5, then I am to use Rounddown(K3,-1) , but if the right most digit is >=5, then I am to use Roundup(K3,-1)
What will be the Excel formula containing both the conditions i.e. " <  " and  "  >=  "
Microsoft ExcelMicrosoft Office

Last Comment
Wayne Taylor (webtubbs)
SOLUTION
CompProbSolv

THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
SOLUTION
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
CompProbSolv

The round(K3,-1) is clearly a much more elegant and compact solution and should be used when the conditions are as specified in the post.  I was trying to give a more generic answer in case the original conditions change.
ASHOK BANERJEE

My sincere thanks to CompProbSolv ,  Wayne Taylor (webtubbs) and   Ben Personick for solving my problem. My gratitude to you all. Thanks once again !
Rob Henson

You can also use the MROUND function:

=MROUND(K3,10)

This will round to the nearest factor of 10.
Asker thanks the experts but failed to follow through with the expected closure.
Microsoft Excel

Microsoft Excel topics include formulas, formatting, VBA macros and user-defined functions, and everything else related to the spreadsheet user interface, including error messages.

144K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts

TRUSTED BY