What is compiling?

Compiling a computer program uses another computer program, a compiler, to transform/translate a program’s source code into another compiled form. The source code is typically written in a high-level programming language and the output code in another programming language.

The level of abstraction of the output code determines whether the process is called compiling or transpiling. When a program source is written in a high-level programming language and is transformed into a low-level programming language it is called compiling. When a program source is written in a high-level programming language and is transformed into another similarly abstracted level of programming language it is called transpiling.

Compiling: the Go programming language
Transpiling: the TypeScript programming language


High-level programming language

A high-level programming language is a programming language which abstracts away some of the details needed to program a computer. A computer requires such components as a processor, memory, and storage. These low-level components can be programmed directly, but most often they are not important when one is interested in programming a high-level program such as a web application for instance. To minimize the details a programmer must consider when writing a program, a programmer can select a high-level programming language to take care of the low-level details automatically.

There may be ways to access the lower-levels while programming in a high-level programming language, but this comes later on in a program’s life. Typically when programming with a high-level programming language at least in the beginning, one is interested in accomplishing some goal with little interest in the underlying details of how a computer is ran. There may be a time when these details become important such as when one wants program to go faster. This may mean increasing the speed at which a unit of work can be performed or the number of units of work can be performed in a duration of time.

Examples of high-level programming languages are: Javascript, Python, Ruby, PHP