wc

wc 命令

命令简介:

简单小巧的计数工具,wc命令用于统计并输出一个文件中行、单词和字节的数目.

Usage: wc [OPTION]... [FILE]...
  or:  wc [OPTION]... --files0-from=F
Print newline, word, and byte counts for each FILE, and a total line if
more than one FILE is specified.  With no FILE, or when FILE is -,
read standard input.  A word is a non-zero-length sequence of characters
delimited by white space.
The options below may be used to select which counts are printed, always in
the following order: newline, word, character, byte, maximum line length.
  -c, --bytes            print the byte counts
  统计字节数
  
  -m, --chars            print the character counts
  统计字符数
  
  -l, --lines            print the newline counts
  统计行数
      --files0-from=F    read input from the files specified by
                           NUL-terminated names in file F;
                           If F is - then read names from standard input
  -L, --max-line-length  print the length of the longest line
  -w, --words            print the word counts
  统计单词数
  
  --help     display this help and exit
  --version  output version information and exit
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

  • 本篇内容:顺序执行、选择执行、管道、cut 命令、grep 命令、wc 命令、sort 命令等,高效率使用 Lin...
    软测小生阅读 1,438评论 0 3
  • 这是统计文本信息速度最快的命令,值得学习一下。 wc命令的功能为统计指定文件中的字节数、字数、行数, 并将统计结果...
    王诗翔阅读 611评论 0 2
  • wc命令的功能为统计指定文件中的字节数、字数、行数,并将统计结果显示输出。 语法:wc[选项]文件… 说明:该命令...
    sunnyRube阅读 1,991评论 0 0
  • wc基本使用 Linux系统中的wc(Word Count)命令的功能为统计指定文件中的字节数、字数、行数,并将统...
    随风化作雨阅读 672评论 0 0
  • 转自[喝小酒的网摘] wc命令用来打印文件的文本行数、单词数、字节数等(print the number of n...
    寒冰豌豆阅读 1,168评论 0 0

友情链接更多精彩内容