xref: /plan9-contrib/sys/man/1/wc (revision 0a4f5b8ee35d2d62b8600a1c256abb8ff2d92d7d)
WC 1
NAME
wc - word count
SYNOPSIS
wc [ -lwrbc ] [ file ... ]
DESCRIPTION
Wc counts lines, words, runes, syntactically-invalid UTF codes and bytes in the named files , or in the standard input if no file is named. A word is a maximal string of characters delimited by spaces, tabs or newlines. The count of runes includes invalid codes.

If the optional argument is present, just the specified counts (lines, words, runes, broken UTF codes or bytes) are selected by the letters l , w , r , b , or c . Otherwise, lines, words and bytes ( -lwc ) are reported.

SOURCE
/sys/src/cmd/wc.c
BUGS
Wc should have options to count suboptimal UTF codes and bytes that cannot occur in any UTF code.