which function automatically counts cells that meet multiple conditions
Count values that meet a condition with the COUNTIF function To learn more about COUNTIF, see COUNTIF function. To learn about an even more powerful function introduced in Excel 2007 that lets you use multiple criteria and ranges, see COUNTIFS function.