How to Count All Items Meeting a Condition via COUNTIF Function

Excel can be regarded as a very powerful office tool ever since it was created. And many functions in Excel can give us a lot of help. And today we will launch the usage of COUNTIF function.

In a worksheet, sometimes you will need to calculate the total number of certain elements in a certain condition. But if you find those cells one by one, you will certainly waste a lot of time. And here is an example of finding how many “A” John has got in his tests via COUNTIF function. And the image below is his scores.John Scores

Count the Total Number

And now you will need to count how many “A” that John has got.

  1. Select a blank cell where you want to put the result in.
  2. Then input the formula: =COUNTIF(B2:I13,”A”).Input COUNTIF Formula

And you can also input this formula: =COUNTIF(B2:I13,B2), because the value of “B2” is “A”.

  1. And then press the key “Enter” on the keyboard. And then know that there are 34 “A” in Paul’s scores.The Total Number

Count the Total Number of Each Test or Subject

Else, if you want to know the numbers of each subject and the numbers in each test, you can also use this formula.

  1. Selected the cell “B14” in this example.
  2. Input the formula: =COUNTIF(B2:B13,”A”).
  3. Press the key “Enter”.Numbers of Each Subject
  4. And then put the cursor to the lower right corner of the cell.Put Cursor to the Corner
  5. Drag with your mouse and then you can see like the image shows:Drag Your Mouse
  6. Release the mouse. And then you can see the result. And now you can know how many “A” in each subject.The Number in Cells

As for each test, the steps are the same except for the area.

Count the Number of Cells within a Range

In the image below, you will need to know the numbers of the scores higher than 90.Scores in Number

And you can also use the COUNTIF function here.

  1. Select a blank cell.
  2. Input the formula: =COUNTIF(B2:I13,”>90″).
  3. Press the key “Enter”. And then you can see the result.The Result Greater than a Goal

Besides, you can also change the conditions to meet your needs.

Excel Corruption and the Repair Solutions

If your need to use Excel to do your work, sometimes you will meet with such conditions: you cannot open an Excel file; or the data stored in Excel files all lost; or the file is just missing from your computer. Thus you may meet with Excel file corruption. You can use a third party tool to fix Excel files. With such a powerful tool, all your important data can be retrieved.

Author Introduction:

Anna Ma is a data recovery expert in DataNumen, Inc., which is the world leader in data recovery technologies, including word recovery and outlook repair software products. For more information visit www.datanumen.com

Leave a Reply

Your email address will not be published. Required fields are marked *