3 ms·
We have a little hubris too. I spent years talking about how dumb Perl was. Then I learned Awk, Bash, and Unix and saw that Perl was a natural and evolutionary
by 3rdAccount 8y ago
We have a little hubris too. I spent years talking about how dumb Perl was. Then I learned Awk, Bash, and Unix and saw that Perl was a natural and evolutionary powerup with a massive script archive. Perl wasn't dumb, I just didn't understand the design decisions. Bash and many dynamic languages are similar. On another note, when I use Java/C# (languages I have little experience in), I always can't help but notice the lack of expressivity. I mean it takes 1/2 page of code to read a text file and print all lines that say "hello". In the Linux shell this could be:
cat filename | grep -i "hello"
Someone else will probably point out a better way. It is also only a couple of lines of Python.
- flukus 8y ago> Someone else will probably point out a better way. It is also only a couple of lines of Python. grep -i "hello" filename # ;) > I always can't help but notice the lack of expressivity. I mean it takes 1/2 page of code to read a text file and print all lines that say "hello" I think you hit the nail on the head there. I've used just about every build system known to man and we're currently using cake at work, which is uses c# as a scripting language. Everything is 10 times more verbose than the equivalent shell/makefile would be. Things like concatenating sql files are 30 lines instead of code instead of one liners.
- kccqzy 8y agoIt's just grep -i hello filename
- deleted 8y ago[deleted]
- 3rdAccount 8y agoHaha, thanks! I always forget :)
- adrianN 8y agoIt takes half a page because you get to choose things like buffering. Error handling is also much nicer.