Translators Flashcards
What are the 2 main translators
Compiler
Interpreter
What does a compiler do
translates all the code into machine code in one go, producing an executable file which can be run.
Pros and cons of a compiler
Much faster to run than an interpreter
The source code must be re-compiled every time the programmer changes the program.
What is an interpreter
translates the code one line at a time, into machine code during program execution.
Pros and cons of an intepreter
Much more effective to debug for individual errors
interpreter code is really slow compared to compiled code.
What is a high level language
easier to write and program as no expertise is needed (closest to human language and understanding)
What are some examples of a high level language
Python,java
Advantages of high level language
easier to program and modify
programs can be written much faster
code can be debugged easily
code is portable across multiple platforms
Dis of high level language
requires more memory than low level languages
translation takes longer and less control over
hardware
What is a low level language
programs written related to specific computer hardware and architecture
Examples of low level language
Assembely language, machine code
Pros of low level lang
assembly language uses English like statements
translated programs require less memory
Cons of low level language
machine code is difficult to understand and takes longer time to write programs
code is machine dependant (not portable)