if [ "$var" = "find" ]; then
echo "found"
fi
Is far more readable than its equivalent [ "$var" = "find" ] && echo "found"
I understand the upside of readability. What does concision get me? if [ "$var" = "find" ]; then
echo "found"
fi
Is far more readable than its equivalent [ "$var" = "find" ] && echo "found"
I understand the upside of readability. What does concision get me?most programmers seems to prefer verbosity.
however in my case verbosity slows me down.
If that's the only criterion, then the parent just followed the logic. Or let's put it another way, if the definition of readability can't survive taking it to the extreme, it is flawed.
wodenokoto offered up some reductio ad absurdum and you are calling it logic.
It was not the only criterion. It was the only criterion that was explicit. There are implied criterion and most of us understand what pwd_mkdb means even if we don't necessarily agree with him.
Well, even in itself, it is wrong.
It's not just that other criteria apply too -- it's that it alone needs several caveats, as succinctness is quite orthogonal to readability (e.g. sometimes even needless boilerplate syntax that the compiler could infer by itself, make for better readability when present).
I am not in disagreement with you about whether it is wrong, I am in disagreement with you about why it is wrong.
The counter argument was that Y is wrong and X is Y, therefore X is wrong. While this is a valid argument, it is not sound, because X is not Y.
> ... succinctness is quite orthogonal to readability ...
There is a relationship between succinctness and readability. The relationship is definitely not directly proportional as the pwd_mkdb's post could be read to imply, but to say there is no relationship between the two is flatly absurd.
That's a bad definition. Readability should be: "code easier to read", not just "less code to read" -- since less is not always easier and can even be much harder.
Case in point: the J language.
Or "magic" constructs that do too much under the scenes and don't let you immediately understand what a part of code is doing.
Concision gets you fewer places to possibly have a bug, and fewer things to possibly miss/misunderstand.