Computers π» | Programming Languages! Translators! IDEs! | 4.2 Flashcards
Define machine code
A binary programming language, for which the code can be loaded and executed without translation.
Define high-level language
(HLL)
A programming language that is independent of computer hardware, that has to be translated into machine code before being executed
Define low-level language
(LLL)
A programming language that is dependent on computer hardware
What are two examples of low-level languages?
Assembly language and machine code
Define assembly language
A programming language that is dependent on computer hardware, for which a program has to be translated into machine code before being executed. It uses mnemonics
Machine code is usually shown in what number system?
Hexadecimal
What are the advantages of high-level languages?
- Independent of the type of computer being used
- Easier to read, write, and understand programs
- Quicker to write programs
- Programs are easier and quicker to debug
- Easier to maintain programs in use
- Portable
What are the disadvantages of high-level languages?
- Programs can be larger
- Programs can take longer to execute
- Programs may not be able to make use of special hardware
What are the advantages of low-level languages?
- Can make use of special hardware
- Includes special machine-dependent instructions
- Can write code that doesnβt take up much space in primary memory
- Can write code that performs a task very quickly
What are the disadvantages of low-level languages?
- It takes a longer time to write and debug programs
- Programs are more difficult to understand
Why are high-level languages easier to understand?
They are closer to english and real world languages
Why may some programmers write programs in an assembly language?
- To make use of special hardware
- To make use of special machine-dependent instructions
- To write code that doesnβt take up much space in primary memory
- To write code that performs a task very quickly
Define translator
Converts a program written in a high-level language into machine code
What is needed to translate an assembly language program into machine code?
An assembler
Why is there need of translators?
Humans find it very difficult to read binary, but computers can only perform operations written in binary