News for hackers. Stuff that matters.
Re:Show HN: Interactively select the quality and format for ... by pushpop on Monday May 27, 2019 @10:06AM (#20022304)
Sure, the the node code uses fewer lines than the Go code. But what you’ve failed to notice is the Go code calls APIs directly rather than fork()ing and does so within its own code base (how many lines of code is in the countless imports of your node example?). Plus the Go code also has unit tests which the others don’t.

Line numbers are always a terrible metric for proving anything but in this case your especially abusing that data.

Re:Show HN: Interactively select the quality and format for ... by w56rjrtyu6ru on Monday May 27, 2019 @10:20AM (#20022390)
In absence of more accessible complexity measurements, line counts do matter somewhat. E.g. the briefer a program is, the more readable it is (last time I checked, brainpower and time is much more expensive than computing power and bandwidth.)

The Node example has zero external dependencies outside of the Node.js standard library.

Re:Show HN: Interactively select the quality and format for ... by ljm on Monday May 27, 2019 @03:00PM (#20024462)
Well, compared to a shell script or a static binary...the Node example requires you to have Node (+ NPM) on your machine and, unless you wrap it all up for homebrew/apt/some other package repo. you're going to be using `npm install -g` to use it as opposed to shoving an executable into your PATH.

All of your stated benefits are nice for the maintainer but mean little to the end user. This gushing praise for Node reads like nobody has ever built elegant CLI apps until Ryan Dahl turned of age and put JS on a server.

Re:Show HN: Interactively select the quality and format for ... by pushpop on Monday May 27, 2019 @12:42PM (#20023391)
> In absence of more accessible complexity measurements, line counts do matter somewhat. E.g. the briefer a program is, the more readable it is (last time I checked, brainpower and time is much more expensive than computing power and bandwidth.)

There are as many exceptions to that rule are there are examples when it’s true. Code golfing, minifified code, shell 1 liners, Perl, etc.

Line counts mean jack shit.

Re:Show HN: Interactively select the quality and format for ... by w56rjrtyu6ru on Monday May 27, 2019 @01:25PM (#20023756)
I would argue that even an esoteric, densely packed one-liner can still be more readable than the equivalent program spread out over a greater number of lines - simply because you can keep it all in sight at the same time and work through it without losing the bigger picture.

But of course, scary symbols is scary.

Re:Show HN: Interactively select the quality and format for ... by mises on Monday May 27, 2019 @04:06PM (#20024913)
So you'd like to use APL, then? He didn't say symbols. Verbose code can be much easier, though stupidly verbose is stupid. Compromise is, as usual, the best solution.
[dead]
Re:Show HN: Interactively select the quality and format for ... by w56rjrtyu6ru on Monday May 27, 2019 @07:32PM (#20026034)
I've created this account with my very own purpose, what about you? It is to lurk less, and it's the first account that sticks because this time I remembered to whitelist HN in my cookie autodeleter.

Nevertheless, it is you who choose to engage with my comments on such a dismissive note. I am prepared that my statements will initially be called ridiculous, but speaking one's mind is a great way to learn faster and there's always plenty to catch up with.