3 ms·
This chart shows the balance between the verbosity of a program written in a language, and the runtime performance of it. The ideal programming language would s
by grey-area 7y ago
This chart shows the balance between the verbosity of a program written in a language, and the runtime performance of it. The ideal programming language would sit at the lower left quadrant.
This is a very odd way to rank programming languages. A language which said nothing and did nothing would be in the lower left too.
I don't mind things being verbose if they are easy to read - compactness is not a good measure of clarity. Code is read far more often than it is written, so this is important, and performance is part of a set of tradeoffs against resource usage etc, it's not a static thing for all situations.
- ImprobableTruth 7y ago>A language which said nothing and did nothing would be in the lower left too. Huh? This is like if I were to argue that I'm one of the top runners in the world since I can't finish a marathon and thus my finish time is 0. A language that is unable to solve the problems would not be listed at all or have an infinite value on the performance axis. >compactness is not a good measure of clarity Solely taking compactness into account is definitely not a good idea, since it just leads to code golfy situations. However, I completely disagree that verbosity isn't a major detractor to readability, since it introduces a lot of noise that detracts from what actually happens. People can only keep track of so many things at once, so the simplicity of a single part often enough comes at the cost at making it harder to understand the whole. It's not a coincidence that 'higher-level' languages are generally less verbose than lower-level ones.
- grey-area 7y agoA language that is unable to solve the problems would not be listed at all I was pointing out the absurdity of using these two criteria in isolation to judge languages, turns out there are other important things like finishing correctly, number of bugs, and clarity, not compactness. I don't think the ideal language can be judged on two criteria (or that there is an ideal language for everyone). However, I completely disagree that verbosity isn't a major detractor to readability, since it introduces a lot of noise that detracts from what actually happens Sure I agree extreme verbosity can be terrible too. So also can extreme terseness, unless it closely matches the problem domain, because otherwise now you have two problem domains you have to be familiar with in order to get work done - the actual problem domain, and the jargon invented by the programmer/language in order to solve it. This depends partly on the person reading and their preference for abstraction.
- brigandish 7y agoI agree but it can go too far too. Last week I had the misfortune to be writing some Applescript. Never will I write a more readable program. I never want to write in Applescript again though!
- grey-area 7y agoApplescript is a really interesting attempt to make something easy to write for people used to english (not sure about easy to read). I've written a fair amount too but dislike it intensely as well - I'm not sure it's easy to read or to write, because the grammar is not well defined and the space of possible keywords and uses is expanded all the time by application developers who define which terms you can use. A very interesting experiment though.