Countif maybe or Lookup??
Hmmm....You only mentioned that you wanted to count pairs of 1's.
For consecutive zeros, try this:
=SUMPRODUCT(($A$3:$A$999<"")*($A$3:$A$999=0)*($A$ 4:$A$1000=0)*($A$4:$A$1000<""))
Does that help?
--------------------------
Regards,
Ron
Microsoft MVP (Excel)
(XL2003, Win XP)
"mpenkala" wrote in message
...
Hi Ron,
This worked great except for the 0 pairs. When I enter
=SUMPRODUCT(($A$3:$A$999=0)*($A$4:$A$1000=0))
It counts all 0's followed by 0's like it should, but also counts all
blank
cells followed by another blank cell. Any way around this? Or do I just
adjust my range?
Thanks,
Matt
"Ron Coderre" wrote:
Try this:
=SUMPRODUCT((A1:A20=1)*(A2:A21=1))
Adjust range references to suit your situation.
Is that something you can work with?
--------------------------
Regards,
Ron
Microsoft MVP (Excel)
(XL2003, Win XP)
"mpenkala" wrote in message
...
Hey,
I'm looking for some help with the following problem. In ColumnA, from
row
3 to 200 I have random numbers ranging between 0 and 50. I'm looking
for
a
formula that will scan through the list of numbers in ColA and find all
the
cell's with "1" in it AND is also followed by "1".
Ex.
ColA
2
0
22
21
45
12
16
6
5
0
0
2
1
19
50
1
1
17
16
28
44
So in this example I would have 1 case of a 1 being followed by another
1.
Thanks for the help,
Matt
|