You are viewing a free preview of this lesson.
Subscribe to unlock all 10 lessons in this course and every other course on LearningBro.
This lesson covers the difference between high-level and low-level programming languages, including machine code and assembly language. This is part of OCR J277 Section 1.5.3.
A programming language is a formal language used to write instructions that a computer can execute. These instructions tell the computer what operations to perform.
Programming languages can be divided into two broad categories:
Low-level languages are closer to the binary instructions that the CPU directly understands. There are two types:
Machine code is the lowest-level programming language. It consists entirely of binary (1s and 0s) and is the only language the CPU can directly execute.
Example (simplified):
10110000 01100001
| Feature | Detail |
|---|---|
| Format | Pure binary (or sometimes hexadecimal) |
| Readability | Virtually impossible for humans to read |
| Portability | Not portable — specific to a particular CPU architecture |
| Speed | Fastest execution — no translation needed |
| Use | Rarely written directly; usually generated by translators |
Assembly language is a low-level language that uses mnemonics (short abbreviations) to represent machine code instructions. It is much easier to read than machine code but still very close to the hardware.
Example:
MOV AL, 61h ; Move the hexadecimal value 61 into register AL
ADD AL, 05h ; Add 5 to the value in register AL
HLT ; Halt the processor
| Feature | Detail |
|---|---|
| Format | Mnemonics (e.g. MOV, ADD, SUB, JMP, HLT) |
| Readability | Difficult but more readable than machine code |
| Portability | Not portable — specific to a CPU architecture |
| Translation | Requires an assembler to convert to machine code |
| Use | Device drivers, embedded systems, performance-critical code |
High-level languages use syntax that is closer to human language and mathematical notation. They are designed to be easier to read, write, and maintain.
| Language | Common Use |
|---|---|
| Python | Education, data science, web development, scripting |
| Java | Enterprise applications, Android apps |
| C# | Windows applications, game development (Unity) |
| JavaScript | Web development (front-end and back-end) |
| C++ | Games, operating systems, performance-critical applications |
Subscribe to continue reading
Get full access to this lesson and all 10 lessons in this course.