Cn Line Counter

Count total lines, non-empty lines, words, and characters in Chinese text from input string or file using a Python script.

Audits

Pending

Install

openclaw skills install cn-line-counter

cn-line-counter

文本行数统计工具。统计文本的行数、字数、字符数。

功能

  • 统计总行数
  • 统计非空行数
  • 统计字数
  • 统计字符数

使用方法

python3 scripts/count_lines.py --text "第一行\n第二行\n第三行"
python3 scripts/count_lines.py --file document.txt

纯Python标准库。