# Excel – find number between two numbers with if formula

In excel if you want to find number between two numbers you can do it by simply using if else condition.

## find number between two numbers

Suppose you have a series of number in cell A1 to A10 and you want to find if the number is between 1 and 10. Simply using formula =IF(AND(A1>=1,A1<=10),1,0)

will give you solution. We have used it to get 0 for false and 1 for true. You can use true/false or yes/no. I have used 0 and 1 as I can use it for condition formatting respective cell more easily. For example I can make 0 cells red and 1 cells green. It depends what you want excel to do after it finds number between two other number

## find time between two times

You can find in excel if a time is between two times with help of this if formula. But note you will have to convert your times between which you want to find times to number or alternately you can use reference for those times. Now the first formula which can be used is below in which we are trying to find times between 4:00 AM and 10:00 AM. =IF(AND(F3>=0.1667,F3<=0.4167),1,0) As you can see above we have changes time to number this you can simply find typing time in a cell and change format to decimal number. In Second formula you can see we have used reference cell to instead of times directly, here you don’t require to change to decimal numbers. =IF(AND(F2>=\$I\$7,F2<=\$I\$8),1,0) These formulas we have tested on Excel 2007 and 2010.