Javascript is interpreted. JavaScript is a lightweight, interpreted or just-in-time compiled scripting language with function priority; code written in JavaScript does not need to be compiled and can be run directly. The browser will directly interpret the source code and create variables in memory. Wait for operations.
The operating environment of this tutorial: windows7 system, javascript version 1.8.5, Dell G3 computer.
What is interpretive type? What is compiled type?
Compiled language is to first compile the source code into machine code (that is, the so-called executable program, such as the exe file of the Windows system). When running The computer only needs to directly hand over the machine code to the CPU for execution. Compiled languages are characterized by fast running speed and high efficiency. The disadvantage is poor portability.
Analytical language appears directly in the form of source code, and is parsed into machine code in real time during operation and executed. All scripting languages (including JavaScript of course) are interpreted languages. The biggest feature of this type of language is that they cannot exist independently and must be parasitic in other programs (such as browsers).
Is javascript interpreted or compiled?
javascript is interpreted.
Javascript is a lightweight, interpreted or just-in-time compiled scripting language with function priority. Unlike C, C and other languages that need to be compiled first and then run, code written in JavaScript does not need to be compiled. Can be run directly.
Also because JavaScript is an interpreted language, this means that the system only knows whether each code is wrong when it is run.
[Recommended learning: javascript advanced tutorial]
The above is the detailed content of Is javascript interpreted or compiled?. For more information, please follow other related articles on the PHP Chinese website!