Nested IF Function

  • Thread starter Thread starter S Swedowski
  • Start date Start date
S

S Swedowski

I asked a question yesterday and got a quick answer and then today I realized
that I had asked the wrong question. :|

Can the IF function look at a number and if
the number is less than 249, add 10
between 250 and 750, add 20
between 751 and 1500, add 30
over 1500, add 40

or is this too much for the IF function.
 
I asked a question yesterday and got a quick answer and then today I realized
that I had asked the wrong question. :|

Can the IF function look at a number and if
the number is less than 249, add 10
between 250 and 750, add 20
between 751 and 1500, add 30
over 1500, add 40

or is this too much for the IF function.  

=IF(A1<249,A1+10,if(and(a1>249,a1<751),a1+20,if(and(a1>750,a1<1501),a1+30,a1+40)))
 
I'm assuming your first condition should include 249, though you state it as
"less than 249".

=IF(A1<=249,A1+10,IF(A1<=750,A1+20,IF(A1<=1500,A1+30,A1+40)))

HTH,
Paul
 
Try this:

=A1+LOOKUP(A1,{0,0.000001,250,751,1501},{0,10,20,30,40})

If A1 is empty it returns 0.
 

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

Similar Threads


Back
Top