2 ms·
...and yet for some reason there are a lot of programmers who believe their job is to produce more code. Fuck those guys. Seriously. I hope this isn
by intransigent 10y ago
...and yet for some reason
there are a lot of programmers
who believe their job is to
produce more code. Fuck those
guys. Seriously.
I hope this isn't a potshot at languages that tend to be verbose.
Coming in cold on a program that someone else has written in a terse programming language that you know well, still sucks. You can know the language, but if you don't know the person doing the writing, terse code can be all but opaque.
With some languages you need some apriori information before attempting to read a thing. Whether it comes in the form of a vulcan mind meld with your best friend, or cultural mores and in-group conventions like managerially enforced coding practices.
Sometimes this is less of a problem with verbose languages, which promote habits and tendencies to be adopted by the author which attempt to indicate intent within code, although any turing-complete language can disappear down a rabbit hole, if the author willfully tries to confuse the reader.
Consider the expressions:
var _something = (data isNaN ? "string" : -1);
In this first example, who the fuck knows what that asshole intended? But there really are people actually expect a declaration like that to be useful?
Compare to:
private static String something = "string";
private static Integer aNumber = -1;
private static boolean numericDataType = false;
Okay, possibly also terrible, and apparently redundant at first glance, but maybe there's a mud pit ahread of us, and some redundant tethering will come in handy.
At least I can see indications of intent, and a separation of ideas.
Maybe the second example involved more keyboard activity, but I can understand it at a glance.
The first example, while shorter, is something I might re-read 3 times, question why anyone would do that, and then find myself re-reading it 10 more times while I debug the all-but-guaranteed garbage that comes immediately after that albatross.