Your Programming Language Can't Understand You...

Laurie holding a C++ book with code syntax examples showing linguistic ambiguity shared by compilers and human language.

Compilers and Humans have the same problem. We're all terrible at understanding each other. Many programming bugs are fundamentally linguistic confusion. Syntactic irregularities affect human languages just like computer languages!

Watch on YouTube

Carlo's take

Linguistic ambiguity isn't just a quirk of human language, it's a fundamental problem shared by programming languages and compilers as well, where the lack of context can cause misinterpretation of even the simplest expressions. Syntax and grammar ambiguities, like the notorious “dangling else” in code or multi-meaning words in English, reveal how both people and machines rely on explicit structure to communicate intent clearly. Ultimately, writing unambiguous code, or sentences, means being as explicit and structured as possible, making interpretation straightforward whether for a human reader or an unforgiving compiler.

More from Wonderland

Wonderland is my hand-picked archive of videos and articles worth your time. Browse all of Wonderland