Start networking and exchanging professional insights

Register now or log in to join your professional community.

Follow

What command do we use to count the total number of lines, words, and characters contained in a file?

user-image
Question added by Faten Almajaly
Date Posted: 2014/06/23
Deleted user
by Deleted user

wc - print newline, word, and byte counts for each file

Examples:

 

> wc todos.txt  =>26 65853

 

> wc -l todos.txt =>26 (lines)

 

> wc -c todos.txt =>853 (bytes)

 

> wc -m todos.txt =>766 (characters)

 

> wc -w todos.txt =>65 (words)

Atif Tanveer
by Atif Tanveer , Decision Support Specialist , Hamilton Health Science

Office2010-13 from Review tab select Word Count in Proofine group. you can also chekc status bar for word and page counts.

Davide Raro
by Davide Raro , Project Manager , COROBOR Systèmes, a Campbell Scientific Company

wc command in fact:

  • wc -l (lines, ex. ls -l | wc -l)
  • wc -m (characters, ex wc -m test.txt)
  • wc -w (words, ex wc -w test.txt)

othman aljundi
by othman aljundi , Senior Systems Administrator (UNIX and Linux) , Orange - Jordan; Jordan Telecom

#wc file_name

 

Ramesh Kumar
by Ramesh Kumar , Admin/HR Officer , Omni Group

In Review Tab in msoffice, Select Word count.

More Questions Like This