Using Between and countif

I

Ify

Using the sample below, I need to count the number of people whose ag
false between 42 and 48.99. How can I use the countif statement or an
other method were possible to achieve the same result ? I have trie
both of these formulas to no avail :
1) =sum((B1:B10>=42)*(B1:B10<=48))
2) =Countif(B1:B10,">=42")-Countif(B1:B10,"<=48")

Example :

Name Dob Age
Peter 01/02/60 44.26
Sunny 31/03/55 49.10
Mark 15/03/60 44.14
Debra 10/07/55 48.83
Jon 29/04/52 52.02
Geff 17/08/61 42.72
Rai 18/05/54 49.97
No.of people between the ages of 42 and 48.99=
 
P

Peo Sjoblom

Use

=Countif(B1:B10,">=42")-Countif(B1:B10,">=49")

or

=sumproduct(--(B1:B10>=42),--(B1:B10<49))
 
A

A.W.J. Ales

Debra,

This will go wrong if there are ages smaller than 42. These will than also
be deducted from the number of ages >= 42.

--
Regards,
Auk Ales

* Please reply to this newsgroup only *
* I will not react on unsolicited e-mails *

Debra Dalgleish said:
The ages are in column C:

=COUNTIF(C1:C10,">=42")-COUNTIF(C1:C10,"<=48")
 
D

Debra Dalgleish

You're right -- I wasn't paying attention to the formula, just the
column reference. It should be:

=COUNTIF(C1:C10,">=42")-COUNTIF(C1:C10,">48.99")
 

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