Want to create interactive content? It’s easy in Genially!
New - LOW-LEVEL AND HIGH-LEVEL LANGUAGES AND TRANSLATION PROGRAMS
Giulia Delogu
Created on October 21, 2024
Start designing with a free template
Discover more than 1500 professional designs like these:
Transcript
PRESENTATION
LOW-LEVEL AND HIGH-LEVEL LANGUAGES AND TRANSLATION PROGRAMS
INDEX
Quizzes
Machine language
Los-level and high-level languages
Translation programs
Computers are devices which follow instructions, but they only understand machine language (or machine code). Machine language is made up of a sequence of 0s and 1s that the computer interprets electrically as instructions. Programmers plan the set of instructions using an algorithm, and they then have to write them in a language that the computer can understand.
However, it is almost impossible for humans to program using a machine language since it is very difficult to remember long sequences of binary code. For this reason, other programming languages were invented; they are easier for humans to write, but computers cannot understand them, so, special translation programs are needed.
Programming languages can be classified into low-level and high-level languages.
low-level and high-level languages
Internet Connection
(LLL) are considered closer to computers and their primary function is to operate, manage and manipulate the computer hardware and components. Programs and applications written in a low-level language are directly executable on the computer hardware without any further translation.
low-level and high-level languages
Internet Connection
Machine language and assembly language are examples of machine-dependent, low-level languages.
Assembly language is less readable, as it consists of short codes and symbols, making it more challenging for programmers to understand at a glance.
low-level and high-level languages
Internet Connection
Example of assembly language:
low-level and high-level LANGUAGES
High-level languages (HLL) were created with the programmer in mind and their syntax is closer to a natural language like English; for example, they have words and a sentence-like structure. For this reason, they are easier to learn and use.
low-level and high-level LANGUAGES
Moreover, they are not machine-dependent and a program, once written, can be used on different types of computers.
low-level and high-level LANGUAGES
High-level languages (HLL):This programming language requires a compiler or interpreter to translate the program into machine language.
Low-Level Languages:
- Low-level languages are like speaking to a computer in its native language.
- They are very close to the computer's hardware.
- Examples: Assembly language, C, C++.
- Used for tasks that need precise control over hardware, like operating systems or device drivers.
High-Level Languages:
- High-level languages are like using everyday language to communicate with a computer.
- They are more abstract and easier for humans to understand.
- Examples: Python, Java, JavaScript.
- Used for general programming tasks, like building websites, apps, and software.
WHAT ARE THE KEY DIFFERENCES BETWEEN...
HIGH-LEVEL LANGUAGES?
LOW-LEVEL AND
In essence, low-level languages are closer to the computer's "brain," while high-level languages provide a more user-friendly way to give instructions to the computer.
Translation programs
Translation programs are like language converters for computers. They take code or instructions written in one programming language (the source language) and convert them into another programming language (the target language) that a computer can understand and execute.
Translation programs
This process allows programmers to write code in a language they are comfortable with and have it transformed into a form that the computer can work with. It's somewhat similar to using a language translator to convert a message from one human language to another.
Translation programs
There are three types of translation programs:
- compilers and interpreters are used for high-level languages
- assemblers for assembly language.
Translation programs A compiler translates the entire source code of a program written in a high-level programming language into machine code (0's and 1's binary form) or an equivalent lower-level language all at once.
Translation programs It cannot fix any error if present in a program; it generates an error message, and you have to correct it yourself in the program's syntax.
Translation programs It generates an object file, and a second, related program, called linker, converts the object file into an executable file.
Translation programs An interpreter takes each line of instruction from the source code in turn, converts it into machine code and executes it one by one, line by line. As the source code is interpreted line-by-line, error detection and correction become easy.
- An interpreter is like a language guide who translates a sentence from one language to another as you speak it.
- Instead of translating the entire program at once, an interpreter reads and translates the code line by line in real-time.
- Think of a compiler like a translator who translates an entire book from one language to another all at once.
- A compiler takes the entire source code written by a programmer in a high-level language and translates it into machine code all at once.
INTERPRETERS
COMPILERS
VERSUS
+ info
Translation programs An assembler translates assembly language into machine code.
Translation programs An assembler is like a code converter that translates a simple code, like a word, into machine code. Assemblers are specific to low-level languages (assembly languages) and translate human-readable assembly code into machine code. They help in writing programs that interact closely with hardware, like device drivers.
Quiz
THANK YOU!