Explain the Levels of Programming Language

Levels of Programming Language:

Programs are a set of instructions or commands needed to perform a specific task by a programmable device such as a microprocessor. The programs needed for a programmable device can be developed at three different levels and they are as follows:

    1. Machine-level programming
    2. Assembly-level programming
    3. High-level programming

Machine Level Programming:

In machine-level programming, instructions are written using binary codes which use only two symbols ‘0’ and ‘1’. The manufacturer of microprocessors will give a set of instructions for each microprocessor in binary codes, i.e., one binary code will represent one operation performed by the microprocessor. The language in which the instructions are represented by binary codes is called machine language. A microprocessor can understand and execute machine language programs directly.

The binary instructions of one microprocessor will not be the same as that of another microprocessor. Therefore, the machine language programs developed for one microprocessor cannot be used for another microprocessor i.e., the machine-level programs are machine-dependent. Moreover, it is highly tedious for a programmer to write programs in machine language.

Assembly Level Programming:

In assembly-level programming, instructions are written using mnemonics. A mnemonic comprises a few letters of the English language which represent the operation performed by the instruction. For example, the mnemonic for the instruction which performs addition operation is ADD. The manufacturer of the microprocessors will provide a set of instructions in the form of a mnemonic for each microprocessor. Also, for each mnemonic, a binary code will be specified by the manufacturer. If the program is developed using binary codes then it is called machine-level programming and if the program is developed using mnemonics then it is called Assembly-level programming.

The language in which the instructions are represented by mnemonics is called assembly language. Microprocessors cannot execute the assembly language programs directly. The assembly language programs have to be converted to machine language for execution. This conversion is performed using a software tool called an assembler.

High-Level Programming:

In high-level programming, the instructions will be in the form of statements written using symbols, English words, and phrases. Each high-level language will have its own vocabulary of words, symbols, phrases, and sentences. Examples of high-level languages are BASIC, C, C++, etc.

The programs written in high-level languages are easy to understand and machine-independent. So they are known as portable programs. A high-level language program has to be converted into machine language programs in order to be executed by the microprocessor. This conversion is performed by a software tool called a compiler.