Types of Translator

The function of the translator is to change the source (program) code into object (machine) code.  There are two main types

  • Interpreter – This checks each line as it as typed for syntax errors. When the program is executed it is translated line by line and the resultant object code is stored in RAM while executed. The Interpreter needs to be present in memory while the program executes.
  • Compiler – This only checks for syntax error when the program is executed. The compiler changes the whole program to object code that is then stored on backing store where it can be executed without the compiler being loaded into RAM.