Is it possible to count number char, line in a file; if so, How?
Answer / Anup Kumar Pandey
Yes, it is possible to count the number of characters and lines in a file using various command-line utilities in Unix-like systems. To count characters (including whitespace), use the `wc -m` command. To count only printable characters, use `wc -c`. To count lines, use `wc -l`. For example: `echo 'Hello World' | wc -m` counts characters and `cat file.txt | wc -l` counts lines in a file.
| Is This Answer Correct ? | 0 Yes | 0 No |
What language is unix written?
What are system variables in unix?
What is .login file in unix?
How do you start and stop services in unix without using admin console?
What is source unix?
What are some common shells and what are their indicators?
What is procedure to configure Mirror rootvg in HP-UX?
Explain what is a fifo?
What are the three major components of any unix system?
What is difference between SSH V1 and SSH V2? What are drawbacks of SSH V2?
What is the full form of unix operating system?
Explain Sticky bit?