Interview Q&A / Linux & Shell

INTERVIEW Q&A · 63 QUESTIONS

Linux & Shell interview questions

Permissions, processes, pipes and the commands you are expected to know cold.

  1. What does the wc command count, and how do you use its options?

    wc counts lines, words and bytes in a file or input. wc -l counts lines, -w words, -c bytes and -m characters. It is most often used at the end of a pipeline, such as grep error log | wc -l, to count matches.

    BeginnerQuick answer1 min read