Translators (CIA) Flashcards
1
Q
What is a compiler?
A
Translates source code from high-level languages into object code, then machine code to be processed by the CPU.
2
Q
What is an assembler?
A
An assembler translates assembly code into machine code.
3
Q
What is an interpreter?
A
It translates source code from higher level languages into machine code, executes the code line-by-line.
4
Q
Advantages of Compilers
A
- Optimized
- Speed of execution is fast
- Secure (source code is kept secret)
5
Q
Disadvantages of Compilers
A
- Use extra memory
- Not cross-platform
- Harder to debug
6
Q
Advantages of Interpreters
A
- Cross-platform
- Easier to debug
- Less memory usage
7
Q
Disadvantages of Interpreters
A
- It is not optimized
- Translation software required at run-time
- Speed of execution is slow
8
Q
Advantages of Assemblers
A
- Memory-efficient
- Speed of execution is fast
- Requires fewer instructions to accomplish the same result
9
Q
Disadvantages of Assemblers
A
- Difficult to remember syntax
- Lack of portability
- More complex, takes more time to code