M
Mike
Hello All,
Using Windows and Excel XP.
I have a spreadsheet that contains numbers in A1:B2. What I want to do is
to check the numbers in A2:B2 to see if those numbers fall in the range of
numbers in A1:B1. If one OR both of the numbers fall in the range I would
like for the formula to return "ok", and if it doesn't I would like for it
to return "NO".
Example #1
A B
-----------------------------------
1 40 37
2 37 12
in this example 37 (in A2) falls in between 40 (A1) and 37 (B1), but 12 (B2)
does not. Because the number 37 (A2) is in the range of 40 (A1) and 37
(B1) I would like the formula to return "ok".
Example #2
A B
----------------------------------
1 22 7
2 30 23
in this example 30 (A2) does not fall in the range of 22 (A1) and 7 (B1) and
the 23 (B2) does not fall in the range of 22 (A1) and 7 (B1). Because the
numbers in A2:B2 do not fall in the range of A1:B1 I would like for the
formula to return "NO".
So I am always comparing the data in row 2 to the data in row 1.
The formula would be something like: =if(A2=rangeA1:B1) OR
if(B2=range(A1:B1),"ok","NO")
I need help writing a correct formula.
Thanks in advance,
Mike
Using Windows and Excel XP.
I have a spreadsheet that contains numbers in A1:B2. What I want to do is
to check the numbers in A2:B2 to see if those numbers fall in the range of
numbers in A1:B1. If one OR both of the numbers fall in the range I would
like for the formula to return "ok", and if it doesn't I would like for it
to return "NO".
Example #1
A B
-----------------------------------
1 40 37
2 37 12
in this example 37 (in A2) falls in between 40 (A1) and 37 (B1), but 12 (B2)
does not. Because the number 37 (A2) is in the range of 40 (A1) and 37
(B1) I would like the formula to return "ok".
Example #2
A B
----------------------------------
1 22 7
2 30 23
in this example 30 (A2) does not fall in the range of 22 (A1) and 7 (B1) and
the 23 (B2) does not fall in the range of 22 (A1) and 7 (B1). Because the
numbers in A2:B2 do not fall in the range of A1:B1 I would like for the
formula to return "NO".
So I am always comparing the data in row 2 to the data in row 1.
The formula would be something like: =if(A2=rangeA1:B1) OR
if(B2=range(A1:B1),"ok","NO")
I need help writing a correct formula.
Thanks in advance,
Mike