Menu
×
   ❮   
HTML CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C C++ C# BOOTSTRAP REACT MYSQL JQUERY EXCEL XML DJANGO NUMPY PANDAS NODEJS R TYPESCRIPT ANGULAR GIT POSTGRESQL MONGODB ASP AI GO KOTLIN SASS VUE DSA GEN AI SCIPY AWS CYBERSECURITY DATA SCIENCE
     ❯   

Google Sheets COUNT 函数


COUNT 函数

**COUNT** 函数是 Google Sheets 中一个预制函数,用于统计包含数字的单元格。

它以 =COUNT 开头,并获取单元格列表。

=COUNT(value1, [value2, ...])

您可以逐个选择单元格,也可以选择区域,甚至多个区域。

注意:**COUNT** 函数仅统计包含数字的单元格,**不**统计包含**字母**的单元格。如果单元格包含字母,则使用COUNTA 函数。


COUNT 函数示例

=COUNT 函数应用于区域 D2:D21。统计精灵总属性的单元格,这些单元格仅包含数字。

复制值

**COUNT** 函数,分步操作

  1. 选择单元格 D22
  2. 输入 =COUNT
  3. 点击 **COUNT** 命令

  1. 指定区域 D2:D21
  2. 按回车键

就是这样!=COUNT 函数成功统计了 20 个包含数字的单元格。



一个无效的示例

现在,让我们尝试一个无法正常工作的示例。

=COUNT 函数应用于区域 A2:A21,该区域仅包含包含字母的单元格。

它返回的值为 0,未找到包含数字的单元格。区域 A2:A21 仅包含包含字母的单元格。


×

Contact Sales

If you want to use W3Schools services as an educational institution, team or enterprise, send us an e-mail:
[email protected]

Report Error

If you want to report an error, or if you want to make a suggestion, send us an e-mail:
[email protected]

W3Schools is optimized for learning and training. Examples might be simplified to improve reading and learning. Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. While using W3Schools, you agree to have read and accepted our terms of use, cookie and privacy policy.

Copyright 1999-2024 by Refsnes Data. All Rights Reserved. W3Schools is Powered by W3.CSS.