90 likes | 226 Views
Interpreters & Compilers. Interpreters . An interpreter takes individual lines off high level languages and converts them into binary. Compilers. Compilers take high level languages and converts the whole code into binary/machine code at once. Translators.
E N D
Interpreters An interpreter takes individual lines off high level languages and converts them into binary.
Compilers Compilers take high level languages and converts the whole code into binary/machine code at once.
Translators Translators are basically a device of converting high level languages for example typing you name and it converts it into binary (1’s and 0’s)
Interpreter the other looks at CompilerInterpreter & Compilers Advantages Disadvantages Interpreters No copy of the machine code is saved. Meaning the source code has to be translated every time taking longer. The process of translating the program slows down the running of it. You will need to have a translator program or you cannot run it. Compilers You have to wait until the code is complete and the errors have been fixed before the translation can be finished and the machine code is run. Each time the program is changed it needs to be re-translate. • Interpreters • Programs run faster even if they are not finished. • Easy to spot errors during translation. • Program can run as soon as first line of translation is completed. • Compilers • The machine code is saved so the program only needs to be translated once • The machine code is saved so the program only needs to be translated once
ERRORS SYNTAX ERRORS ARE WHEN A COMPUTER CODE IS WRITTEN INCORRECTLY (E.G. PRIT INSTEAD OF PRINT) AN EXECUTION ERROR IS WHEN A SYSTEM TRIES TO RUN AND THE WRONG CODE HAS BEEN WRITTEN. A LOGIC ERROR IS WHEN THERE IS AN ISSUE IN THE PROGRAM THAT CAUSES IT TO OPERATE INCORRECTLY