In recent cow brush off network, a problem is found. Do a question, if if written with c ++ language, either in time or space, the effect is better than java.
With my own knowledge, I can think of it, that is a little fur, because c ++ is a compiled language, but java is interpreted language. And what is a compiled language , what is interpreted language it ?
Compiled language: the program before execution requires a special compilation process, the program files compiled into machine language translation does not need to re-run, the direct result of using the compiler on the line. High efficiency of program execution, depending on the compiler, cross-platform poor. c, c ++, Delphi and so on.
Interpreted language: does not need compilation, when translated into machine language program runs each time we perform a translation. So efficiency is relatively low. For example, the Basic language, there is a dedicated interpreter Basic program can be executed directly, when each statement is executed only translation. Efficiency is relatively low, dependent on the interpreter, cross-platform is good. Run: first translated into an intermediate code, and then executed by an interpreter.
Interpreted and compiled explanation and description:
1. compiled language
Compiled language refers to the all-time code is compiled, then executed.
Advantages: speed execution; disadvantages: low development efficiency.
2. interpreted language:
Interpreted language refers to each compiling an execution sentence.
Advantages: development of high efficiency; disadvantages: slow speed of execution.
Note: When very large amount of code, there are tens of thousands of lines even more often, just put all the code to compile, you may need to spend a few hours of time. Thus, once the code is wrong, for compiled languages, it would need to start compiling heavy head, extremely time consuming.
Development of low efficiency, but his execution is fast. Instead interpreted language, explain each one, on the implementation of the way, once the error can be corrected in time, continue to compile, therefore, the development of high efficiency, but slower.