I need a formula that returns True or False if a number is found in a specific array.

  • Thread starter Thread starter BigDubbe
  • Start date Start date
B

BigDubbe

I need a formula that returns True or False if a number is found in
specific array
 
{=IF(SUMIF($C$2:$C$8,E7,$C$2:$C$8)=E7,"true","false")}


$C$2:$C$8 would be the range of numbers. E7 would be the number yo
are lookig for.

Don't forget the array brackets
 
Gbonda wrote...
{=IF(SUMIF($C$2:$C$8,E7,$C$2:$C$8)=E7,"true","false")}


$C$2:$C$8 would be the range of numbers. E7 would be the number you
are lookig for.

Don't forget the array brackets.

Why not forget them since they're unnecessary?

And if the value sought appeared several times in the array, your
formula returns "false". Whether or not that's what the OP intended is
up to the OP to decide.

If the OP wants True or False boolean values rather than text strings
returned, it'd be easier to use

=COUNTIF(Array,Number)>0

if one or more matches should correspond to TRUE or

=COUNTIF(Array,Number)=1

if one and only one match should correspond to TRUE.
 

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

Back
Top