answersLogoWhite

0


Want this question answered?

Be notified when an answer is posted

Add your answer:

Earn +20 pts
Q: How an interpreter translates the high-level code to machine code?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Computer Science

What is post compiler?

A compiler translates anything that is a structured syntax, generally a computer language, into machine code or code that an interpreter will execute on a computer. Machine code actually executes on a machine, interpreted code is pure data for the execution engine of the interpreter.Post compilers, sometimes called post processors, take the compiled code as input and make changes to the code to provide functionality beyond that of the original language.Examples are:The original C++ language used a C compiler to process most of the file and a post compiler to add the object-oriented extensionsAspect Oriented Programming (AOP) functionality is generally added by a post compiler


What is the difference between a compiler and an interpretor?

A compiler will read your entire source code and convert it into a language specific to the environment it's intended to run on. The plan is to have the compiler analyze the code and build an efficient application.Examples of languages that are compiled: C, C++, JavaAn interpreter will read your source code, usually line by line, and execute each command one at a time. This is slower and less efficient, but very good for teaching programming.Examples of languages that are interpreted: Basic, Turing, LogoA compiler translates a high-level language to a low level language all at once. An interpreter only translates one high-level statement at a time.


What ias computer interpreter?

A computer interpreter is a type of program that allows computer code written in a high-level programming language to be executed by the computer. Interpreters work by translating the code into machine code, which is the language that the computer's processor can understand and execute. Unlike compilers, which translate high-level code into machine code before the program runs, interpreters execute the code line-by-line, translating each line into machine code and executing it as it goes. This makes it possible to run code in an interactive or iterative manner, making debugging and testing easier and facilitating rapid prototyping. Interpreters are commonly used in scripting languages like Python, Ruby, and JavaScript, which are often used for web development and other applications where code needs to be executed quickly. They are also used in some programming languages like BASIC. Overall, interpreters provide an essential way for programmers to write and execute code more efficiently and effectively, making it possible to create applications and software that can run on a wide range of systems.


What are the classification of computer software and definition?

Software is a set of programs used to operate computers and related devices.The two main classifications of software:System softwareApplication software1) System software - software designed to operate the computer hardware and to provide a platform for running application software.Operating Systems are a collection of programs that make the computer hardware conveniently available to the user and also hide the complexities of the computer's operation.Utility programs are small, powerful programs with a limited capability, they are usually operated by the user to maintain a smooth running of the computer system.Library programs are a compiled collection of subroutinesTranslator software (Assembler, Compiler, Interpreter)Assembler translates assembly language programs into machine code (A binary code that a machine can understand).Compiler translates high level language code into object code (which is the machine language of the target machine).Interpreter analyses and executes a high-level language program a line at a time. Execution will be slower than for the equivalent compiled code as the source code is analyzed line by line2) Application software - software designed to help the user to perform specific tasks.General purpose application software.Special purpose application software.Bespoke application softwarefor more help visit essayguardian(dot)com


What is Human readable?

Any document that a human can read and understand without requiring an interpreter (it is written in the reader's native language, for instance). Machine code is not human-readable, it is intended to be read by a machine. Assembler language is a symbolic language that is essentially a human-readable form of machine code, however it's not easily understood by everyone except those familiar with Assembler language. High-level languages are more easily understood by most programmers, particularly those familiar with the language, while pseudocode is an abstract language intended to be human-readable even by non-programmers.

Related questions

What are the names of 2 type of language translators?

Two types of language translators are: a compiler, which translates the entire source code into machine code before running the program, and an interpreter, which translates and executes the source code line by line.


State two differences between a compiler and an interpreter?

# An interpreter translates from source code to machine code on-the-fly; a compiler does it all before the program is executed. # Compilers can spend a lot of time on analysis and optimization, allowing for (generally) better performance of code.


What are the similarities between compiler and interpreter?

Both compiler and interpreter are the language programs that translates source program into machine code or we can say object code. Both are used to find errors in source program.


Why machine language is the only language which is directly executed by computers?

Machine language is the native language of the machine and requires no translation. Every other programming language must be translated into machine code in order to execute, which means you need to program the computer to perform that translation. A compiler translates the entire source code to produce a machine code executable, whereas an interpreter translates high-level statements as they are executed within the runtime environment.


What translates a high level language into machine code?

An interpreter or a compiler. The former translates one line at a time and must be executed within the interpreter. The latter compiles the entire program into a standalone executable. For example, C++ is compiled to machine code but Java is compiled to byte code which is then interpreted by the Java Virtual Machine.


What is a computer interpreter?

An interpreter, or a translator, is a person who translates different languages. For an example, if a Chinese person and an American person can't understand each other, an intepreter can translate for both of them.


What is a compiler and an interpreter?

a compiler translates an entire program and then executes it while an interpreter translates and executes one line of a program at time


How does an interpreter translate high-level code to machine code?

A computer does not execute a program in a high level language. A computer executes a program in machine language. The high level language is converted into machine language by a compiler. Alternatively, an interpreter executes on the computer in machine language and the interpreter executes the high level language.


Why does an interpreter not convert source code into machine language?

A traditional interpreter interprets the source code instructions at runtime, and executes them directly. Compiling the instructions into machine code is not part of of a traditionally interpreter's design.However, many modern interpreters work differently from traditional interpreters. In the traditional concept, an interpreter would digest the exact source code instructions at runtime, parsing "if" and "else" and so forth.Most modern interpreters compile (!) the source code into code fit for a virtual machine (sometimes called hypercode or p-code). This virtual machine is implemented as an interpreter, which interprets and executes the stream of hypercode instructions at runtime. This is more efficient, since the interpreter doesn't have to handle surplus input (such as comment), and can rely on the input to be pre-validated for syntactic and, to some extend, semantic correctness.Most modern virtual machine interpreters support another compilation step at runtime, typically called just-in-time compilation or JIT for short. With JIT, the virtual machine translates portions of the hypercode into real machine code at runtime, thus improving execution speed for repeatedly executed code.Popular programming languages such as Java or the .NET languages all work on this principle.


What is a program that translates a high level language like C plus plus to machine language?

A compiler. We can also use an interpreter to translate high-level code as it is executed, however in order to create a stand-alone executable we must use a compiler. A compiler is simply a program that translates high-level code to a lower-level code (but not necessarily machine code). For instance, the Java compiler emits Java byte code which is suitable for interpretation by the Java virtual machine.


Is jvm a compiler?

Basically they do the same: converting from one level of language into another. A compiler converts high level language (programming language like java) into machine-language. That is language a computer understands. An interpreter converts high level language into an intermediate level. When a program is exectuted, that intermediate level is reconverted to machine language.


What works with one source statement at a time translating it to machine level instructions?

Are you asking about an "interpreter"? That's part of a computer language that reads a line of code and breaks it down into machine code. The Interpreter works with one source statement at a time, reading it, translating itto machine-level instructions, executing the resulting binary instructions, and then moving on to the next source statement. Almost no real interpreters generate any machine code, they simply interpret the source code and directly do what it says using machine code built into the interpreter when it was originally written. Machine code is generated by compilers, to permit repeated execution without having to reload the compiler each time (as one must with an interpreter).