Each high-level programming language classification analysis

More recently contacted understanding of language, now analyze the same classification

Language is divided into two types based on: (As far as I understand the language of the contact)

① strongly typed language:
c ++; c; c #; Java - must be taken to distinguish between data types

Pre-defined variables need to set this variable what type of data stored crude.
② weakly typed language:
you can not pay particular attention to data types js, php-- storage type is automatically converted

Definition of variables can store any type of data.

Example: JS which is: var a; representative of mixed types, when all of the definitions of all variables beginning with var.


Javascript is a browser side scripting language used in web client-side processing and user interaction, and achieve page effects. For example, before submitting the form to verify the legitimacy of data, server errors and reduce pressure. According to customer operations, give some tips to make the user experience better and so on. Beautiful page design, animation and so on.

 

Compiled and interpreted languages

The computer can not directly understand high-level language, can only be understood directly machine language , it is necessary to make high-level language into machine language the computer can execute programs written in high-level language.
It is a compilation, one explanation. Two ways at different times just translation. Compiled language before writing the program execution, requires a special compilation process, to compile become Files machine language, such as exe files, they wanted to run, then do not re-translated directly use the compiled results on the line (exe file) because only translated once, run-time translation is not required, so the high efficiency of program execution of compiled languages, but can not be generalized, some interpreted language interpreter by dynamically optimizing code at runtime, even the interpreted language performance than a compiled language.
Interpretation is different, interpretive language does not need compilation, saving procedures, interpretive language translation only when running the program , such as basic interpretive language, there is a special interpreter capable of performing basic program directly, each statement is performed only when the translation. Such an interpreted language Each time a translation is necessary, the efficiency is relatively low . Interpretation is the translation of a sentence.
Compiled and interpreted languages ​​pros and cons
The former because the program fast execution, under the same conditions, low system requirements, so as to develop an operating system, large-scale applications, database systems isochronous have adopted it, like C / C ++, Pascal / Object Pascal (Delphi) , etc. are compiled language, and some web scripts , server script and assist in developing such an interface speed of less demanding, there are certain requirements for compatibility between different systems platforms procedure is usually interpreted languages , such as JavaScript, VBScript, Perl, Python, Ruby, MATLAB, and so on.
But with the upgrade and hardware design changes, compiled and interpreted languages more general (such as the Java compiler and a half semi explanation), mainly in the emerging high-level language, and interpreted languages also makes its own characteristics compiler vendors are willing to spend more to optimize the cost of the interpreter , interpreted language performance than a compiled language is inevitable.

Guess you like

Origin www.cnblogs.com/sengzhao666/p/11918926.html