Worst ideas/features in programming languages?

Imperatorn johan_forsberg_86 at hotmail.com
Sun Oct 24 10:53:17 UTC 2021


On Sunday, 24 October 2021 at 10:21:22 UTC, claptrap wrote:
> On Sunday, 24 October 2021 at 08:42:54 UTC, Ola Fosheim Grøstad 
> wrote:
>>
>> It us equally puzzeling why prople want "&&" instead of "and" 
>> or "||" instead of "or". There is no rational explanation, I 
>> think people like to feel that they are using something 
>> advanced and that a syntax that that is associated with 
>> advanced usage makes them feel more skilled? Kinda like 
>> fashion...
>
> 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?

This might be a good reason actually.

Coming from logic I at first thought that of course "or" would be 
∨ and "and" would be ∧ etc, but then, where are those signs on my 
keyboard 😭

(I actually have an apl keyboard but that's another thing)

So made sense in a way to reuse & and | since they are pretty 
close as alternative representations, ie ∥ VS || for example.


More information about the Digitalmars-d mailing list