Search code examples
excelexcel-formulaexcel-2010excel-2007

How to define a range of values while writing IF condition in Excel?


I am trying to write a NestedIF to sort out if people are Young, Middle aged or Old. now I want to get "Middle Aged" for all the values between 25 to 65.


Solution

  • Try this

    =IF(A1<25,"Young",IF(AND(A1>=25,A1<=65),"Middle Aged","Old"))