
Is HTML a programming language
Recently, more and more various Internet resources have been hosting holivars on the topic: is HTML a programming language or not. As usual, there are a considerable number of arguments in favor of both points of view, so I decided to put an end to myself in this unnecessary argument.
Programming language is a formal sign system designed to record computer programs. The programming language defines a set of lexical, syntactic and semantic rules that determine the appearance of the program and the actions that the executor (computer) will perform under her control.
This is stated on Wikipedia , and most of the other resources either fully use this definition, or freely set forth it without loss of meaning. Consider in more detail the components of the definition of PL:
In a simpler language, this can be stated as follows:
A programming language is a set of predetermined, monotonous and understandable to the executor (read: interpreter / compiler / computer / programmer) instructions intended to be written sequentially for the purpose of execution by a certain device that is part of a computer. Also, the programming language should have a number of features: there should be a limited number of instructions, and everyone should know them; instructions should be built in a certain way to obtain certain results, and everyone should be aware of this; there must be rules for writing instructions and everyone should know them; each language construct must unambiguously correlate what is written with what was required to be designated.
It turned out so bulky and ugly, but without complicated words. We will return to this definition a bit later.

Often also used the division into low-level and high-level languages. These types are distinguished by the "thickness of the layer" between the processor and the programmer. In simple words, in low-level languages, each instruction represents one or a small number of processor instructions, and in a high-level language, each instruction is a large set of processor instructions.
Let's take a closer look at the definitions of different types according to Wikipedia :

All programming languages are divided into two groups: declarative and imperative .
A program in an imperative programming language from a mathematical point of view is a general solution to the problem, in other words, the answer to the question "how to do?" This is a sequence of commands that an executor must execute.
A program in a declarative programming language is a combination of a task formalized within the framework of a programming language and all the theorems necessary for its solution, in other words, the answer to the question “what to do?”. A specific sequence of actions performed by the compiler, or more often the interpreter, is a program that executes program code in real time without converting it to machine code.
In computability theory, a performer (a set of computational elements) is called Turing-complete if any computable function can be implemented on it. In other words, for each computable function there is a calculating element (for example, a Turing machine ) or a program for the executor, and all functions computed by many calculators are computable functions (possibly with some encoding of the input and output data).
The name comes from Alan Turing , who came up with an abstract calculator - a Turing machine and defined many functions that can be calculated using Turing machines.
In other words, the language is Turing completeif any computable function that you need can be written in this language and solved by its executor.

Incomplete Turing languages also exist, but since they are created mainly for academic purposes, they are little known and are not widely used.
Conclusion: We can call HTML a programming language only in the context of formal polemics. In fact, it is a hypertext markup language and nothing more. But the reader must understand that if there are no clearly defined standards, then no one forbids making a language identical in syntax to HTML, but interpreted in a completely different way so that it is Turing-complete.
Definition of a programming language
Programming language is a formal sign system designed to record computer programs. The programming language defines a set of lexical, syntactic and semantic rules that determine the appearance of the program and the actions that the executor (computer) will perform under her control.
This is stated on Wikipedia , and most of the other resources either fully use this definition, or freely set forth it without loss of meaning. Consider in more detail the components of the definition of PL:
- A formal language is a set of finite words (lines, chains) over a finite alphabet.
- A sign system is a system of uniformly interpreted and interpreted messages / signals that can be exchanged during communication. Sometimes sign systems help to structure the process of communication in order to give it a certain adequacy in terms of the reactions of its participants to certain “signs”. Language is usually cited as an example of a sign system (both in writing and, in the case of natural languages, in the form of speech).
- Computer program - a sequence of instructions intended for execution by a control device of a computer.
- Vocabulary is a collection of words of one or another language, part of a language or words that is known to one or another person or group of people.
- Syntax is the side of a programming language that describes the structure of programs as sets of characters (usually they say - regardless of content). The syntax of a language is contrasted with its semantics. The syntax of a language describes a “pure” language, while semantics ascribes meanings (actions) to various syntactic constructions.
- Semantics in programming is a discipline that studies the formalization of the meanings of constructs of programming languages by constructing their formal mathematical models. Various tools can be used as tools for constructing such models, for example, mathematical logic, λ-calculus, set theory, category theory, model theory, universal algebra. Formalization of the semantics of a programming language can be used both for describing a language, determining the properties of a language, and for the purposes of formal verification of programs in this programming language.
- Language is a sign system that correlates conceptual content and typical sound (spelling).
In a simpler language, this can be stated as follows:
A programming language is a set of predetermined, monotonous and understandable to the executor (read: interpreter / compiler / computer / programmer) instructions intended to be written sequentially for the purpose of execution by a certain device that is part of a computer. Also, the programming language should have a number of features: there should be a limited number of instructions, and everyone should know them; instructions should be built in a certain way to obtain certain results, and everyone should be aware of this; there must be rules for writing instructions and everyone should know them; each language construct must unambiguously correlate what is written with what was required to be designated.
It turned out so bulky and ugly, but without complicated words. We will return to this definition a bit later.
Types of programming languages

Often also used the division into low-level and high-level languages. These types are distinguished by the "thickness of the layer" between the processor and the programmer. In simple words, in low-level languages, each instruction represents one or a small number of processor instructions, and in a high-level language, each instruction is a large set of processor instructions.
Let's take a closer look at the definitions of different types according to Wikipedia :
- Aspect-Oriented Programming (AOP) is a programming paradigm based on the idea of dividing functionality to improve the partitioning of a program into modules.
- Structural programming is a software development methodology based on the presentation of a program in the form of a hierarchical block structure. It was proposed in the 70s of the XX century by E. Dijkstroy, developed and supplemented by N. Wirth.
- Procedural programming - programming in an imperative language, in which sequentially executed statements can be assembled into subprograms, that is, larger integral units of code, using the mechanisms of the language itself [1].
- Logical programming is a programming paradigm based on automatic proof of theorems, as well as a section of discrete mathematics that studies the principles of logical inference of information based on given facts and rules of inference. Logical programming is based on the theory and apparatus of mathematical logic using the mathematical principles of resolutions.
- Object-oriented programming (OOP) is a programming paradigm in which the basic concepts are concepts of objects and classes. In the case of languages with prototyping, prototype objects are used instead of classes.
- Functional programming is a section of discrete mathematics and a programming paradigm in which the calculation process is treated as calculating the values of functions in the mathematical understanding of the latter (as opposed to functions as subprograms in procedural programming).
- A multi-paradigm programming language is usually a programming language that was developed specifically as a multi-paradigm programming tool, that is, the pictorial capabilities of which were originally supposed to be inherited from several, most often unrelated languages.
- Esoteric programming language is a programming language designed to explore the limits of possibilities for developing programming languages, to prove the potential implementation of an idea (the so-called “proof of concept”, English proof of concept), as a piece of software art [en], or as jokes (computer humor).
Imperative and declarative approach

All programming languages are divided into two groups: declarative and imperative .
A program in an imperative programming language from a mathematical point of view is a general solution to the problem, in other words, the answer to the question "how to do?" This is a sequence of commands that an executor must execute.
A program in a declarative programming language is a combination of a task formalized within the framework of a programming language and all the theorems necessary for its solution, in other words, the answer to the question “what to do?”. A specific sequence of actions performed by the compiler, or more often the interpreter, is a program that executes program code in real time without converting it to machine code.
Turing completeness
In computability theory, a performer (a set of computational elements) is called Turing-complete if any computable function can be implemented on it. In other words, for each computable function there is a calculating element (for example, a Turing machine ) or a program for the executor, and all functions computed by many calculators are computable functions (possibly with some encoding of the input and output data).
The name comes from Alan Turing , who came up with an abstract calculator - a Turing machine and defined many functions that can be calculated using Turing machines.
In other words, the language is Turing completeif any computable function that you need can be written in this language and solved by its executor.

Incomplete Turing languages also exist, but since they are created mainly for academic purposes, they are little known and are not widely used.
We will answer a few questions:
- Is HTML a language?Yes. It has properties inherent in languages.
- HTML - matches the definition of a programming language?Yes. It has syntax, semantics, vocabulary, it is a language and falls into the category of declarative programming languages.
- Is Turing a complete language?Not. Simply put in HTML, you can only perform some limited set of actions interpreted by the browser.
- Can HTML be called a programming language?Depending on the context, yes it is. But it should be remembered that with the same success can be called YaP and CSS and XML and SQL. In other words, these languages can formally be called programming languages, but only with a certain degree of skepticism and with full understanding that these languages do not satisfy all the requirements.
- Is HTML a programming language?Not. The task of a common programming language is data processing, and the task of HTML is data mapping. It is not a programming language and cannot be used for calculations.
Conclusion: We can call HTML a programming language only in the context of formal polemics. In fact, it is a hypertext markup language and nothing more. But the reader must understand that if there are no clearly defined standards, then no one forbids making a language identical in syntax to HTML, but interpreted in a completely different way so that it is Turing-complete.