Yes, absolutely! You can combine options in wc just like many other Linux commands.
You can combine them in two ways:
-
Grouped symbols: You can put the letters together after a single dash. For example, to see both the line count and the byte count:
wc -lc /etc/passwd -
Separate symbols: You can list them individually:
wc -l -c /etc/passwd
Examples of combinations:
wc -lw: Displays lines and words.wc -wc: Displays words and characters.wc -lwc: Displays all three (this is the same as the default output when you runwcwithout options).
This is a great way to filter exactly the information you need. Give it a try in your terminal!