Skip to content

Ask an Academic

  • Home
  • Ask a Question
  • Contact Us
Picture of a data centre

The Difference Between Interpreters and Compilers

September 20, 2019 by AskanAcademic.com

Question

distinguish between interpreter and compiler?

Answer

Both interpreters and compilers are used to translate source code into object code. Although they both achieve the same end objective, the method in which they do so is substantially different.


Interpreters

• Input a single instruction at a time.

• No intermediate representation (code that provides a programmer with ability to optimise the code based on the target machine).

• Control statements (‘If’ statements) are slow to execute.

• Errors are displayed for every interpreted instruction making them both easy to notice but slow to produce.

• Interpreters require less memory to function as no intermediate code is created.

Compilers

• Input the entire set of instructions at once.

• Provide intermediate representation.

• Control statements are faster to execute.

• Errors are not produced after each instruction meaning that the compiling is fast, but mistakes are often difficult to notice.

• Compilers require more memory as they create intermediate code.

Conclusion

Essentially the main difference between the two is their level of approachability and in the case of varied target machine architecture, their practicability. For novices, interpreters may be slower but they provide an easier method for detecting errors in source code and aid in producing an error free object code. Compilers on the other hand for experienced users provide a much quicker method of producing object code, however they do not provide the same degree of problem recognition. The addition of intermediate code produced by compilers also allows a programmer to tailor their code to particular target machines, often making compilers more practical.

References

Post navigation

Previous Post:

Comparing Computer Vulnerabilities and Threats

Next Post:

The status of women in Uganda

Search Q&As

Categories

  • Art Media and Literature (74)
  • Business and Management (256)
  • Computing and ICT (14)
  • Construction and Engineering (35)
  • Education (90)
  • Environmental Sciences (2)
  • Finance and Economics (91)
  • Health (64)
  • Languages (12)
  • Law (88)
  • Mathematics and Statistics (2)
  • Medical Sciences (19)
  • Politics and International Relations (83)
  • Research Methodology (1)
  • Science (49)
  • Social Sciences (101)

Archives

Who We Are

Askanacademic.com is owned and operated by All Answers Ltd, a company registered in England and Wales. Company Registration No: 4964706. VAT Registration No: 842417633. Data Controller No: Z1821391.

Registered office:
Venture House
Cross Street
Arnold
Nottingham
NG5 7PJ

Main Navigation

  • Home
  • Ask a Question
  • Contact Us

Legals

  • Cookie Policy
  • Privacy Policy

Popular Categories

  • Business and Management
  • Law
  • Finance and Economics
  • Health
An an Academic Logo
© 2023 Ask an Academic | WordPress Theme by Superb Themes
This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Accept Reject
Read More
Privacy & Cookies Policy

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.
Non-necessary
Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.
SAVE & ACCEPT