Countif Help

R

Richard

Hi,

I have a list of 8 intitials in a row (C7 : J7), such as AR, IR, CS, RP etc.
These are 4 golfing pairs.

How do I count the number of times "AR" AND "IR" appear anywhere on row
C7..J7?

E.g.
if both "AR and "IR" appear in range C7 : J7, the result of "1" would be
returned in K7.
if just "AR" appears, without "IR", the result of "0" would be returned in
K7.

I'm stumped - any assistance would be appreciated

Tks - Rick
 
R

Roger Govier

Hi Richard

One way
=MAX(0,SUMPRODUCT(--(C7:J7="AR")+(C7:J7="IR"))-1)

Regards
Roger Govier
 
R

Rohinikumar

Hi May be this can help you.
just click another cell and copy this below format
=COUNTIF(C:C,"AR")
 
B

Bob Phillips

Why would it be there more than once?

Although I don't feel that the spec is clear, here is a shot

=INT(SUM(COUNTIF(C7:J7,{"AR","IR"}))/2)

HTH

Bob
 

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