What is interpreter ?
Definition: In computing, an interpreter is a computer
program that reads the source
code of
another computer program and executes that program.
Because it is interpreted line by line, it is
a much slower way of running a program than one that has been compiled but is easier for learners because the program can bestopped,
modified and rerun without time-consuming compiles.
What is compiler ?
Generally
compiling is a term which is often heard by everyone who is associated with
programming, even if remotely. A compiler is a program which converts a high
level language program/code into binary instructions (machine language) that
our computer can interpret, understand and take the appropriate steps to
execute the same
The main difference between Compiler and Interpreter : The compiler executes the entire program at a time, but the interpreter executes each and every line individually.
·
The interpreter takes one statement then translates it and
executes it and then takes another statement. While the compiler translates the
entire program in one go and then executes it.
·
Compiler generates the error
report after the translation of the entire page while an interpreter will stop
the translation after it gets the first error.
·
In a compiler the analyzing and
processing time of the program is more, while an interpreter spends less time
for the program analyzing and processing.
·
Compiler translates the
high level instruction into machine language, but the interpreter
translates the high level instruction into an intermediate code.
No comments:
Post a Comment