to display the number of blank spaces in a specified file
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
This sounds like homework to me. So I will say that one way to solve this is by using 'sed' and 'wc', for more info see the man pages 'man sed', 'man wc' as well as:
Even for a homework job a bit more info would be needed. Does it have to be done by standard command-line tools, or rather as a | Perl | PHP | Ruby | Python | <your favorite scripting here> | script? Maybe even as a compiled binary? There are a lot of ways to do it, depending where the project is heading to.
That's bull. I don't see these requirements in the rules.
This is not school its the real world. Wake up.
OK---I'm awake.
Since you have read the rules, you know that the key statement is--in effect--that you cannot expect help on homework.
Since you have been here for a while, you also know that people DO very often get help on homework. If you read my statement as a criteria for getting help, maybe you can feel better.
If it helps, I'll stipulate that it is my opinion.
That's bull. I don't see these requirements in the rules.
This is not school its the real world. Wake up.
Hey, if you wanna tell them the answer, go right ahead, I'm not stopping you, and the mods may not either. Just know that you are doing the OP a disservice by doing this.
[slightly offtopic, but not really] You know it'd be kind of cool if you could have a man page give you information about just a particular option that an executable has, like say, man grep -o, and man would spit out a small grep description and that options description, or maybe it would be better if it gave just the description of the option since it would have to be a pretty good parser to pick out just one option like -c out of the wc man page. Ah well maybe someday someone will add that option to man.
[slightly offtopic, but not really] You know it'd be kind of cool if you could have a man page give you information about just a particular option that an executable has, like say, man grep -o, and man would spit out a small grep description and that options description, or maybe it would be better if it gave just the description of the option since it would have to be a pretty good parser to pick out just one option like -c out of the wc man page. Ah well maybe someday someone will add that option to man.
Moreover, it can be useful if you can specify a topic as for man grep "character classes" and man spits out the relevant section of the man page, especially for very extensive pages.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.