Can't figure out formula in Numbers app

I hope I get to find a solution for this…

I have 3 cells in Numbers
C3 = “A”
C4 = “B”
C5 = “Original”

Now, I would like to have a formula that evaluates both C3 and C4, and if both are not their original values, then change C5 to “New”.

It seems that the formulas I tried always seem to change C5 when one of the values in C3 or C4 changes. This was the closest I got, but not working either:

IF(
C3≠"A",
IF(
C4≠"B",
"New",
"Original"
),
"Original"
)

if you rather see it in a single line:

IF(C3≠"A",IF(C4≠"B","New","Original"),"Original")

With this formula this is what I get in different scenarios (the first 3 are expected)

image

image

image

This one is the one that’s not expected (I mean, it’s expected because of the formula, but not what I expect it to do)

image


EDIT: I had to use AND, (which wasn’t working when ChatGPT offered something similar) but also use the “not equal to”, because using the “equal to” was not helping for some reason. Final formula:

IF(AND(C3≠"A",C4≠"B"),"New","Original")

Never mind, not my day. Sorry.

Here’s a way to use OR and not need the ≠ operator.

3 Likes

That’s a clever way indeed. Thanks for sharing.
Is there a reason why using ≠ would be “bad”?
Or you just wanted to share an alternative?

It’s an alternative using a key easily found on the keyboard. ⌥=, ≠, is not easily found.

2 Likes

Makes sense. Thank you!

Good old De Morgan’s law. Not understanding it has caught a lot of programmers.

1 Like