Worst ideas/features in programming languages?

claptrap clap at trap.com
Sun Oct 24 20:46:01 UTC 2021


On Sunday, 24 October 2021 at 14:47:48 UTC, Ola Fosheim Grøstad 
wrote:
> On Sunday, 24 October 2021 at 10:21:22 UTC, claptrap wrote:
>> Because boolean algebra was already a thing and it was 
>> symbolic in nature. So making it wordy would probably seem a 
>> bit odd, maybe childish to some people. It'd be like writing 
>> arithmetic expressions like this...
>>
>> 1 plus 1 equals 2
>>
>> If you can understand why people wouldn't want to write 
>> arithmetic expressions like that, surely you can understand 
>> why some people wouldn't want wordy boolean expressions?
>
> I think "not being childish" is a sign of fashion-elitism if it 
> makes code less legible. Many languages that predated C++'s 
> uptake did use more intuitive syntax and had a less noisy 
> appearance.

I dont think it does make code less legible. I mean the whole 
point of using symbolic expressions is that they make it easier 
to express things. It's not fashion, and it's not elitism. If 
you're writing a ton of boolean expressions over and over using a 
symbol instead of a word to express a concept will make it 
easier. It may increase the learning curve for people coming to 
it fresh, but that doesn't mean that is reason for doing it.


> I have found that using them makes my own code slightly faster 
> to read, so I have recently started to use them.

So you find them slightly faster to read, and anyone who doesn't 
use them must be showing off?


> Makes sense to me that "if", "while", "or", "and" ties to flow 
> control, and "&", "|", "+", "/" ties to calculating expressions.

But they are not part of control flow, they are part of 
expressions.


> The line noise does of course make programs look more 
> impressive to non-coders: "Whoa, that looks complex, you must 
> be very clever".

Yeah cause programmers go around showing their code to non coders 
to try and impress them. In fact it's my number one way to chat 
up women, show em some over complicated code till they fall 
swooning into my arms.

What are you smoking mate?



More information about the Digitalmars-d mailing list