nesting if statements

G

Guest

OK let me try to explain this one...

Cell A1 has a number between 0 and 75.

Cell A2 needs to have some nested If statements that reflect the following:
If A1 is between 2 and 4 then A2 should read 80
If A1 is between 5 and 14 then A2 should read 120
If A1 is between 15 and 24 then A2 should read 160
If A1 is 25 and higher then A2 should read 200
 
G

Guest

=IF(AND(A1>2,A1<4),80,IF(AND(A1>5,A1<14),120,IF(AND(A1>15,A1<24),160,IF(A1>25,200))))

Yoou used "between" and so that is how I set up the formulas...
In other words, the following inputs in A2 give the following results:
1 = FALSE
2 = FALSE
3 = 80

You may want to set up a table that allows you to link the formulas so that
you can easliy change the values...

Jim
 
D

dominicb

Good evening tjb

You haven't indicated wha is to happen if the number in cell A1 is 0 o
1 - in the example below, 0 is returned. Other than that I think i
covers your requirements.

=IF(A1>=25,200,IF(A1>=15,160,IF(A1>=5,120,IF(A1>=2,80,0))))

HTH

Dominic
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top