Excel formula: Count cells not equal to
Author: Sun Last Modified: 2024-09-26
To count the number of cells that contain values that not equal to a specified value, such as below screenshot shown. In Excel, you can use the COUNTIF function to quickly handle this job.
Generic formula:
COUNTIF(range,”<>value”) |
Arguments
|
Example:
Count the number of cells that not equal to “Apple” in the given list, choose one of below formulas
=COUNTIF(B2:B8,"<>Apple") |
Or
=COUNTIF(B2:B8,"<>"&E2) |
In above formulas, B2:B8 is the range of cells that you want to count from, Apple and E2 is the value you want the cells not equal to.
The press Enter key to get the counted result
Sample File
Relative Formulas
- Count cells equal to
With the COUNTIF function, you can count cells that equal to or not contain a specified value. - Count cells that equal to x or y
In some times, you may want to count the number of cells that meet one of two criteria, in this case, you can use the COUNTIF function. - Count cells equal to x and y
Here this article introduce the formula to count cells that at the meanwhile match two criteria. - Count cells greater than or less than
This article talks about how to use the COUNTIF function to count the number of cell that greater than or less than a number
The Best Office Productivity Tools
Kutools for Excel - Helps You To Stand Out From Crowd
Kutools for Excel Boasts Over 300 Features, Ensuring That What You Need is Just A Click Away...
Office Tab - Enable Tabbed Reading and Editing in Microsoft Office (include Excel)
- One second to switch between dozens of open documents!
- Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
- Increases your productivity by 50% when viewing and editing multiple documents.
- Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Edge and Firefox.