How to check if each value in a cell range is contained in a second cell range?

M

ModelerGirl

For example, suppose I have a range

1
2
3
4
5

and a second range

2
3
6
6
7

Is there a formula that would return a value of, say, 1 for each valu
in the first range that is NOT contained in the second range.

For example, here, I would want to return

1
0
0
1
1

Thanks very much,
Kat
 
R

Ron Rosenfeld

For example, suppose I have a range

1
2
3
4
5

and a second range

2
3
6
6
7

Is there a formula that would return a value of, say, 1 for each value
in the first range that is NOT contained in the second range.

For example, here, I would want to return

1
0
0
1
1

Thanks very much,
Kate

=--(COUNTIF(rng2,A1)=0)


--ron
 

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