Sponsored Link

Sponsored Link

Monday, September 15, 2008

Using IF and AND to Classify

This is a very common scenario that I have came across. This is first thing I did when I opened MS Excel in 2000. In fact this query is raised by one girl in my MS Excel community on Orkut.

The IF formula below classify based on the value A1.
Above 70 - ,"CONGRATS KEEP IT UP",
70 to 60 - "Good Work"
and so on

Formula:
=IF(A1>70,"CONGRATS KEEP IT UP",IF(AND(A1>60,A1<=70),"GOOD WORK",IF(AND(A1>45, A1<=60),"MUST WORK HARD","BAD")))

1 comments:

Flukey said...

There is no need for an AND here, as you are testing the same value. It can be done this way:

=IF(A1>70,"CONGRATS KEEP IT UP",IF(A1>60,"GOOD WORK",IF(A1>45,"MUST WORK HARD","BAD")))

Post a Comment