 So, I'm up here at my office today and I'm checking a bunch of YouTube comments. And I got a ton of comments from the video I did the other day talking about various command line ways of getting line counts of terminal output. And one of the most common comments I got on that video the other day is the fact that I had many instances of a useless use of cat, UUOC, the useless use of cat. And this is one of the most annoying troll kind of comments that we get in the Linux community, freedom of source software community, scripting and programming community, is anytime somebody uses the cat command incorrectly, you know, immediately somebody cries, that's a useless use of cat, which let's be honest, nine times out of ten when you use the cat command, it is, I guess in these people's opinion, useless because cat, what the cat command does, it takes input, such as a file name, the contents of a file, and writes that to standard output. And then many people will then pipe the output from cat into another command, such as grep said, all the other day I was using WC, the word count program. People were like, you shouldn't cat a file name and then pipe it into WC because WC can take that input directly. So you're wasting a thread, a process, because you don't even need the cat command. So you're adding all this extra work to your computer, you know, a few cycles of the computer. I don't know. But these people, they have a point, but at the same time, they're rather ridiculous, because honestly, the only time you really need to tell somebody that they're doing a useless use of cat is if they're actually doing scripting. Like if you see somebody writing a bash script, and it includes any instance of cat, immediately a red flag should go up, you know, if you're writing a script and you're using cat, you should know, hey, there's probably a better way to do this. But when you're doing things interactive at the terminal, right? And that's what I'm doing. I'm not scripting with cat. I'm not, you know, I would never cat into WC in a script. I know better, right? And what's crazy is these people crying, useless use of cat, they know I know better, right? As a matter of fact, when I did all of my stuff the other day, every instance of cat that I used in that video I knew was a useless use of cat. And I didn't care because it saved me time. Why did it save me time? It's because, you know, I'm demonstrating things. So first I cat my bash RC. So I write cat bash RC, right? And then I just up arrow to get that cat command again, and then just add a pipe, and then WC, right? Because that's a lot easier than writing a whole new command, right? Instead of, hey, I cat my bash RC. And then next, let me show you the WC command, which is WC dash L, name a file. Well, I don't have to, I don't want to write all that. I just up arrow, and then tack on pipe WC dash L, right? And then, because I was also going to show like half a dozen different ways to do the same thing, it makes it a lot easier because then I can up arrow and just remove WC dash L and then do whatever I was doing with grip, said, awk, cut, you know, whatever command I was using. So technically, I was not doing a useless use of cat, right? I knew exactly what I was doing and it had a use. It saved me from typing, because otherwise all those commands, even though they can take a file name directly as input, typically the format for that is name of command, file name, you know, the name of the command is at the beginning of the command. And that's tedious for me to up arrow and then backspace a million spaces to delete the command at the front of the command and then rewrite the new command when I can just, because I catted and then piped it into the command where the command is at the end of the command, that makes it a lot easier because I can just up arrow the cursors already on the command that I want to delete and change to a different command. It makes it a lot easier on me. And honestly, it makes it better when I'm demonstrating this stuff on camera. So these people that are crying useless use of cat, it's not a useless use of cat. You're wrong. And what's really crazy is because I think a lot of these people with their useless use of cat mindset try to avoid using cat ever. Many of them don't realize that some of these commands I run where I take cat and pipe it into something else actually do do different things, because I got at least 10 different people the other day telling me that catting file name and then piping it into WC is exactly the same as WC file name. That's not actually the case. Right now on your computer, open a terminal and then what I want you to do is do a wc-l dot bash rc. Get a line count on the bash rc. See what the output is. Now I want you to do cat dot bash rc, pipe it into wc-l. Look at the output. Guess what? They're different. They don't actually do the same thing. So the people crying useless use of cat, unless you're talking about somebody actually scripting with the cat command, you have no point. Right? Anybody doing anything interactive at the command line and they're using cat, just leave them alone. Quit crying useless use of cat. Like you have some kind of special knowledge. Like, you know, you really know something that somebody else doesn't because half the time, like you guys crying about the WC command, you don't even know what you're talking about because, again, catting into WC actually is different than just doing WC file name. So in my opinion, there's no real useless use of cat outside of scripting and programming. You will never hear me tell somebody, hey, that's a useless use of cat because I know better. I know that I don't know, you know, the thought process why that person was using cat. They may have a legit reason and I'm not going to pretend like I have some kind of superior knowledge. So I will never cry useless use of cat. Now I won't do that, but I will make a video like today and tell you guys that there's a lot of useless bitching and moaning about the useless use of cat and way too many of you guys are guilty of that. Anyway, ran over. Peace.