Math
COUNT
Definition
COUNT returns how many of the supplied values are numbers.
Syntax
=COUNT(value1, [value2], ...)
Arguments
| Argument | Meaning |
|---|---|
value1 |
The first item to check: a cell, a range such as B2:B5, or a typed value. |
value2, ... |
Optional extra items or ranges to check as well. |
Worked example
A help desk logs how long each ticket took. One cell says n/a and another was never filled in. The minutes sit in B2:B5.
| A: Ticket | B: Minutes |
|---|---|
| T-1 | 47 |
| T-2 | n/a |
| T-3 | 63 |
| T-4 | (blank) |
Formula: =COUNT(B2:B5)
Result: 2. Only 47 and 63 are numbers; the text n/a and the empty cell are skipped.
Practice
Range E2:E6 holds 12, the word pending, 40, 7, and an empty cell. Write a formula that returns how many numbers it contains.
- In E7, write a COUNT formula for E2:E6.
- E7 should show how many numbers are in E2:E6.
Related functions
COUNT says how many numbers there are, SUM adds them, and AVERAGE is what you get when the second is divided by the first.
Common mistake
Pointing COUNT at a column of names and getting 0 because text is not a number; COUNT only works for numeric cells.