grep Command in Linux : What is grep Command ?
Linux du Command Example | Linux show disk usage
Linux sort Command Examples | Sort files or directory in Linux
Linux cat command Example | Linux print file content on terminal
What is NIC In Hindi ? Network Interface Card Kya hai ?
PHP Program to check whether number is Palindrome or not | PHP Find Palindrome Number
Web Performance In Hindi : Website Performance Kya Hai?
PHP stdClass In Hindi | stdClass In PHP
Hardware Boot Process क्या है | Computer Boot कैसे होता है ?
If tutorials available on this website are helpful for you, please whitelist this website in your ad blocker😭 or Donate to help us ❤️ pay for the web hosting to keep the website running.
Image by pixabay
Linux में wc
command का use किसी file में words / line व characters count करने के लिए किया जाता है। हालाँकि इसमें और भी options होते हैं जिन्हे आप wc --help
command run करके देख सकते हैं।
$ wc --help
Example के लिए हम एक test
name की file बनाकर उसमे content insert करेंगे , फिर wc command का use करके word count करेंगे
$ toch test $ cat > test hello ! how are you? I hope , you are getting it :) press ctrl+d to save and exit.
Note* Linux में touch command का use file create करने cat command का use file में content write और concatenate करने के लिए किया जाता है।
File content में word count करने के लिए -w option का use किया जाता है।
$ wc -w test 13 test
File में lines print करने के लिए -l
option का use किया जाता है।
$ wc -l test 3 test
characters print करने के लिए -m
option का use किया जाता है।
$ wc -m test 52 test
byte counts, print करने के लिए -c
parameter का use किया जाता है।
$ wc -c test 52 test
Loading ...
Hi ! I'm Rahul Kumar Rajput founder of learnhindituts.com. I'm a software developer having more than 4 years of experience. I love to talk about programming as well as writing technical tutorials and blogs that can help to others. I'm here to help you navigate the coding cosmos and turn your ideas into reality, keep coding, keep learning :)
Get connected with me. :) LinkedIn Twitter Instagram Facebook