0
How different is an interpreter from a compiler and a translator?
1 Answer
+ 1
Compiler converts the program from one computer language to another computer language. A compiler has to cope with any valid syntax in the source language, and generate semantically equivalent code in the target language. It basically scans the entire program and translates it as a whole into machine code.
An interpreter is similar to a compiler, but it translates one statement at a time.
Translator which translate one language to many other language or else we can say a translator is usually translating from a high level language to another high level language, or from a low level language to a high level language. A translator usually has a fixed body of code that is required to translate the program.