What Is Compiler And Interpreter?
Compiler: A compiler is program that converts the instruction of a high level language into machine language as a whole. A program written in high level language is called source program. After the source program is converted into machine language by the compiler, it is called an object program. The compiler checks each statement in the source program and generates machine instructions. Compiler also checks syntax errors in the program. A source program containing an error cannot be compiled into an object program. A compiler can translate the programs of only that language for which it is written. For example C++ compiler can translate only those programs, which are written in C++. Each machine required a separate compiler for each high level language. Interpreter: An interpreter is a program that converts one statement of a program at a time. It executes this statement before translating the next statement of the source program. If there is an error in the statement, the interpreter