📜  编译语言和解释语言的区别

📅  最后修改于: 2021-09-10 03:01:29             🧑  作者: Mango

先决条件 – 编译器与解释器

编译语言:
编译语言是一种通常被编译而不是解释的编程语言。它是一种程序,一旦被编译,就在目标机器的指令中表达;这个机器码是人类无法破译的。编译语言的类型——C、C++、C#、CLEO、COBOL 等。

口译语言:
解释型语言是一种编程语言,通常是解释型的,而不是将程序编译成机器指令。在这种情况下,指令不是由目标机器直接执行,而是由其他程序读取和执行。解释语言范围——JavaScript、Perl、 Python、BASIC 等。

让我们看看编译语言和解释语言之间的区别:

S.NO. COMPILED LANGUAGE INTERPRETED LANGUAGE
1 A compiled language is a programming language whose implementations are typically compilers and not interpreters. An interpreted language is a programming language whose implementations execute instructions directly and freely, without previously compiling a program into machine-language instructions.
2 In this language, once the program is compiled it is expressed in the instructions of the target machine. While in this language, the instructions are not directly executed by the target machine.
3 There are at least two steps to get from source code to execution. There is only one steps to get from source code to execution.
4 In this language, compiled programs run faster than interpreted programs. While in this language, interpreted programs can be modified while the program is running.
5 In this language, compilation errors prevent the code from compiling. In this languages, all the debugging occurs at run-time.
6 The code of compiled language can be executed directly by the computer’s CPU. A program written in an interpreted language is not compiled, it is interpreted.
7 This language delivers better performance. This languages delivers relatively slower performance.
8 Example of compiled language – C, C++, C#, CLEO, COBOL, etc. Example of Interpreted language – JavaScript, Perl, Python, BASIC, etc.