IF>OR<ABD

O

oldjay

I can't get a result for the following

If a1=1 or a2=2 and a3=3 then a4=4 otherwise 0
 
P

Per Jessen

Hi

I think this is the formula you need in A4:

=IF(OR(A1=1,A2=2),IF(A3=3,4,0),0)

Regards
Per
 
B

Brian

That formula is like:

if (a1=1 or a2=2) and (a3=3) then a4=4 otherwise a4=0

But the original post could just as well be interpreted as:

if a1=1 or (a2=2 and a3=3) then a4=4 otherwise a4=0

As an example, if a1=1, a2=2 and a3=0, these two interpretations give
different results (the first gives a4=0 and the second gives a4=4).
 

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