How to be proficient in C language from the perspective of language level
---July 12, 2017
---ning brother QQ 1455153071
---Public number: Ning brother real-combat classroom
When it comes to C language, many people's first reaction is to define variables, If...else ... Such detail grammar, however, should not be forgotten at all times is its position in the programming world. The former is the grammatical details, the latter is more need a macroscopic understanding, can understand it more and more deeply. Why there is a saying that "Ten years do not dare to say proficient in C language" there is a certain truth. So, here we look at the C language from a macro perspective.
Programming languages start with 0101 of these machine code programming, then programming is really a kind of only high IQ people can do the work, because you have to recite a bunch of instructions, such as: The add instruction is assumed to be 10011100, you have to remember! Therefore, this kind of programming to be troublesome, also is unfavorable to popularize, the number strength is limited, cannot make the function too powerful.
So the predecessors improved according to the social needs, provided the original translator: the Assembly. So that people no longer need to write machine instructions such as: 10011100, and just write add, through the Assembly tool can convert add to machine code, thus simplifying the programming, this is the original programming language for humans: assembler. However, this language does not solve one thing, that is, you write instructions are determined by the machine CPU instruction system, meaning, different CPU instruction system determines that you write the instructions are not the same. That is, the transplant problem, this is not the assembly language produced, but the original, the assembly is not solved.
The problem of portability is not solved, so the same software on different platforms will have to re-write a set, very troublesome.
So the higher-level programming language should appear, this is the C language. It solves the CPU instruction system cross-platform, but more and more hardware operation, are encapsulated as a variety of drivers, by the operating system to carry, so now the cross-platform is not only to the CPU instruction system cross-platform, but also to include the operating system cross-platform. This will continue to produce more advanced cross-platform, such as: java. Java is achieving a more perfect cross-platform by making intermediate bytecode, rather than the final binary approach.
Although it is functionally resolved, it is the quality of the code that is sacrificed. The better the compatibility, the more exceptions need to be considered, fault tolerance will do better, the code will be more, so the function of the compiler more and more powerful, powerful means that performance will be reduced, as the overall efficiency is determined by a number of key links in the series circuit together, the worst link determines the overall efficiency. Therefore, the higher the upper programming language, the lower the performance is bound to be. Performance: Powerful things need to be developed in the underlying language. Therefore, the game industry engine is not suitable for PHP and Java to develop, are used in C + + to develop ... Otherwise it will get stuck to death ... In the same way, installing software and software that is very card in the app is the result of the inability to solve performance problems due to the development of the upper language.
So, whether people are pursuing the hot industry: embedded, Mobile Internet, IoT, cloud computing, big data, these performance is better, it must be C/s to support. More technology industry, water to the depths, is the implementation of C + +.
Such as: Missile sailing speed of 8000 m/s. Imagine your program if there is a 0.1-second error, then you will have an error of 800 meters, which is not the point where to fight, but the east hit the west, playing the irrelevant.
Horseshoes great difference, this sentence is ubiquitous in the field of programming efficiency and performance.
Now is the pursuit of speed, speed, or speed!!!
1: Performance Comparison reference:
The most efficient is the machine language. Its performance is about twice times the assembly language, and the assembly language is twice times the C language, and C is 1.5 times times of C + +, C language is 5 times times the Java;
If from the speed of view: Machine language execution 1 seconds, assembly language to 2 seconds to complete, C language to 4 seconds to complete, C + + to 6 seconds, Java to 20 seconds to complete, yellow flower estimates are cool.
The more advanced the language, the slower the speed;
2: The level of language development summary:
Icon:
650) this.width=650; "Src=" https://s4.51cto.com/wyfs02/M00/9C/11/wKiom1lsBTzxj7AWAAFYj5VKh7U610.png-wh_500x0-wm_ 3-wmp_4-s_210975156.png "title=" Clipboard.png "alt=" Wkiom1lsbtzxj7awaafyj5vkh7u610.png-wh_50 "/>
3: C-language status ...
The core position of C language is seen here as the base language for other languages such as C + + and higher-level languages. C language is not good, C + + is difficult to master, C + + learning is not good, Java difficult to master, PHP is also difficult to master, JS is also difficult to master, data structures and algorithms must learn basic courses. Linux operating system is difficult to grasp. These are all coherent together, like applying for a high-paying PHP position, others are not test your PHP syntax, but ask you Linux operating system, data structure, NoSQL these went.
C language is the most important programming language ever, to get into the programming industry master level must learn C language, of course, to earn a lot of money has to be proficient in C language. It is the subject of science and engineering in all universities and the core programming language of future science and technology. is almost all enterprises, foreign companies, high-paying programming job interview than Test content. To be a hacker, red guest must also master the programming language.
So, is: learn C + +, all over the world are not afraid. Now hurriedly the C language ..., whether you are doing. NET, Java, or PHP, or js ... "C language, good cool" 2017, it was born for it!
This article is from the "C Language good cool" blog, please be sure to keep this source http://ningcaichen66.blog.51cto.com/2902291/1948085
How to be proficient in C language from the perspective of language level