Count if

  • Thread starter Thread starter Robert
  • Start date Start date
R

Robert

Hi,

I am trying to count the number of individuals in two seperate columns on
the same spreadsheet:
For exemple, in my column A, some cells have "Robert" and in Column B, some
cells have "Robert". I want to know how many times we have "Robert" side by
side.
Cell A1 = Robert and Cell B1 = Robert
I dont want to count all the other cells where Robert is shown but not
beside another Robert

Many Thanks

Robert
 
Hi,
try

=SUMPRODUCT(--(A2:A6="Robert")*(B2:B6="Robert"))

change range to fit your needs
 
What is the double unary minus doing for you in this situation, Eduardo?
Isn't --1 the same as 1, and --0 the same as 0?
 
Hi David,
you are right, I was in excel and just enter the double unary, isn't doing
anything
 
Back
Top