(Programming|Computer) Language or Code
If you have ever studied a second language yourself and then tried to use it outside the classroom, you know that there are three things you must master:
- how the language is structured (grammar),
- how to name things you want to talk about (vocabulary),
- and the customary and effective ways to say everyday things (usage).
Too often only the first two are covered in the classroom, and you find native speakers constantly suppressing their laughter as you try to make yourself understood. It is much the same with a programming language…. Grammar and vocabulary are properties of the language alone, but usage is characteristic of a community that uses it….the customary and effective ways to structure your code. G. L Steele Jr in Effective Java (2nd Edition)
The limits of my language mean the limits of my world. Ludwig Wittgenstein Tractatus Logico-Philosophicus (1922)
Table of Contents
1 - About
For natural language, see (Natural|Human) Language - Text (Mining|Analytics)
A program, often referred to as source code or just code, is a set of special instructions that tell the computer what tasks to perform.
The rules for valid format and combinations of instructions is called a computer language, sometimes referred to as its syntax (or grammar), much the same as English tells you how to spell words and how to create valid sentences using words and punctuation.
- static languages
Code is read far more than it's written
It's extremely easy to read:
- and explicit code.
With code reuse, your lines of code will start to shrink.
If you encounter a frustration or an unexpected behavior of a language feature, your response should be to add it to the blacklist.
2 - Articles Related
3 - Language Type
- Text-based computer languages based on sequences of characters
- Visual programming languages based on the spatial layout and connections between symbols
4 - Structure / Building Block
The following expressions are the basis building block of any language:
- conditionals flow like if statements to make decisions.
- loops to repeat tasks until a condition stops being true.
- operators to perform basic known operation on value.
- comment to document the code.
The definition on how you write of all this building block is called a grammar.
5 - Core language
5.1 - Scripting / Dynamic Language
5.2 - Compiled Language
5.2.1 - At Build time
5.2.2 - At runtime
5.3 - Query Language
5.4 - Markup and Style Sheets language
5.5 - DSL
6 - Static vs Runtime
Our intellectual powers are rather geared to master static relations and that our powers to visualize processes evolving in time are relatively poorly developed. For that reason we should do (as wise programmers aware of our limitations) our utmost to shorten the conceptual gap between the static program and the dynamic process, to make the correspondence between:
- the program (spread out in text space)
- and the process (spread out in time)
as trivial as possible. Dijkstra (1968) - A Case against the GO TO Statement
7 - Lexical Analysis
8 - Language Features
Computer languages differ not so much in what they make possible, but in what they make easy. Larry Wall
9 - Turing tarpit
A Turing tarpit (or Turing tar-pit) is any programming language or computer interface that allows for flexibility in function but is difficult to learn and use because it offers little or no support for common tasks.
10 - Documentation / Reference
- Simpson, Kyle. You Don't Know JS: Up & Going (p. 28). O'Reilly Media.