Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wc clarity #963

alouyakis opened this issue Apr 19, 2019 · 1 comment


None yet
3 participants
Copy link

commented Apr 19, 2019

The Unix Shell: Lesson 4. Pipes and Filters
Word count without flags is used to initially introduce the command and outputs three points of data - character, word, and line count. Then -l is added to show how line count is attained. It would be helpful to also include wc -cwl to show that the output is the same as default without flags. This would help by teaching about default flags and also increase exposure to varied usage by showing -c and -w in addition to -l. A possible addition (without showing the output):

$ cd molecules
$ wc *.pdb

The default flags for the wc command are -cwl. If we run wc -cwl instead of just wc, the output will be identical:

$ wc -cwl *.pdb

Each flag can also be used individually. By running wc -l instead of just wc, the output shows only the number of lines per file:

$ wc -l *.pdb

This comment has been minimized.

Copy link

commented Apr 29, 2019

Thanks for the suggestion, a PR would be welcome to discuss default options.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.