(reprint) Hello, C + + (2) 1.3 C + + world map 1.4 How to learn C + +

Source: Internet
Author: User
Tags ftp file ftp file transfer

1.3 C + + world map

The development process of C + + language is not only a process of increasing features and enriching content, but also a continuous gongchenglvede process in the field of application. In its more than 30-year development process, C + + has been widely applied and developed in many fields of application. Whether on the initial unix/linux operating system, on the Windows operating system, or even on the recently emerging embedded systems, C + + occupies an irreplaceable place, as shown in 1-3.

Figure 1-2 C + + world three points

1.3.1 C + + development under the Windows system

Since Gates completed Windows 1.0 in C/C + + in 1985, C + + has forged a bond with the Windows operating system. Not only is the Windows operating system low-level, but most of the large software running on the Windows operating system is developed using C + +. It can be said that the Windows operating system is flowing in C + + blood. Although there are many programming languages on the Windows operating system, C + +, with its unique advantages and historical accumulation, still has an unshakable position on the Windows platform.

1. Unique Advantages

The Windows operating system itself is a close relationship developed in C/s + +, which makes C + + call the Windows API (application programming Interface, application programming interface, It is usually a pre-defined function of the operating system or programming framework, so that programmers can access the functionality provided by the system with a natural advantage. Therefore, when developing programs related to Windows operating systems, it is often preferable to choose the C + + language.

2. The accumulation of history

For historical reasons, many applications running on Windows operating systems are developed using C + +, and these applications still need to be maintained and upgraded. Therefore, C + + has a first-class advantage on Windows operating systems.

C + + development under the 1.3.2 Unix/linux system

If there are other competitors in C + + under the Windows operating system, C + + is almost the right choice for developing languages under the Unix/linux operating system.

As a programming language, the advantages of C + + under the Unix/linux operating system are obvious. First, the Unix/linux operating system itself is developed in C + + language, which makes the operating system itself very friendly to C + + development. In addition, most of the Unix/linux operating systems are server-side applications that emphasize high performance and high security, which is precisely the strength of the C + + language. Most of the applications on Unix/linux are developed using C + +, such as the famous Web server Apache, database server MySQL, and so on. Therefore, if you want to develop the application on the Unix/linux operating system, when the performance requirements are high, but also require a faster development efficiency, then C + + must be the preferred development language.

C + + development under 1.3.3 Embedded system

With the popularity of a variety of digital products, embedded systems have gradually become a hot development area. The special hardware limitation of embedded system makes the embedded system have special requirements for developing language. For example, due to the small instruction set of the execution unit, only the relatively concise syntax of the development of the language, embedded system memory capacity is small, requires good management of memory; the embedded system has low CPU frequency, which requires the executable code to be simple and efficient, and to improve the efficiency of development, Requires advanced development language and so on. These demanding requirements of the embedded system for developing languages are simply not easy to reverse the C/s + + language, and are exactly the advantages of C + +. C + + syntax is relatively simple, can be implemented on the embedded system, it is close to the bottom, can be good management of memory, its compiled generated executable code is simple and efficient, and its own high-level programming language, development efficiency can be guaranteed. C + + is very good to meet the requirements of embedded system development language, almost become the only choice of embedded system development.

1.4 How to learn C + +

Now that C + + is so powerful, how do we learn C + +?

Almost every C + + beginner will ask this question. However, this problem does not have a so-called standard answer. As a guide of the C + + world, I can introduce some knowledge and experience to everyone, let everyone less detours, go in the right direction, easy and enjoyable to complete the C + + world wonderful journey. As long as you grasp the following two principles, as to the specific learning methods, we need to find ourselves.

1.4.1 "Read and write more thinking" is the only way to learn C + +

C + + is a very practical technology, we can not just rely on reading a few books to learn C + +. Remember when we were learning English, the teacher always taught us to "listen more and say more read and write more"? Similarly, learning C + + also needs to emphasize "reading and writing". For programming languages, although there is no "listen" and "say", but "more reading" and "more write" is also applicable, coupled with a "more thinking", this is the only way to learn C + +.

1. Multi-read

Multi-reading is the emphasis on reading and learning other people's excellent code, especially some excellent open source products (such as the text editor program notepad++, FTP file transfer program FileZilla, etc.) source code. By reading these source code, not only can learn the specific language knowledge it uses, development technology, but also can learn its design ideas, programming style and so on. The so-called "Jinzhuzhechi, Howl", to master learning, is to become a shortcut to master.

2. Write more

To write more, is to do more development practice. Programming is a skill, it comes from practice, and must be returned to practice. It is impossible to learn programming well. Multi-write includes many aspects, for example, in the development environment to complete the sample program, re-implementation of the network of routines, development and implementation of some small programs. The purpose of multi-reading is only to learn the knowledge and experience of others, the purpose is to write the knowledge and experience of others into their own knowledge and experience. At the same time, through the multi-write can find in practice many in the "multi-reading" process is hidden problems, let our understanding and understanding more profound. At the same time, through their own program, debugging procedures, can gain valuable first-hand development experience, training their own hands-on ability, thus become a real master.

3. Think more

Do the above "read and write more", can let us become a good developer, but not let us become a professional software engineer.

"Read more and write" emphasizes the ability to implement code, but to become a professional software engineer, it is not enough to just write code. We must also have the ability to design, have the ability to abstract, analyze, design algorithms, and ultimately solve problems with a program. And "think more" is precisely to give us the design of this lesson.

To put it simply, every component of a good program (class or function, etc.) is designed to solve a problem. So, in the face of good code, what we need to think about is, what's the problem? Why design it like this? Is there any other better way? Only in this way can we understand why good code is good. In the face of similar problems, will be comprehend by analogy, design the same good code.

In this world, there is never a programming language that is learned only by reading one or two reference books, just as no one can learn to write a novel just by reading the introduction to fiction. We must constantly read, learn, think about other people's good code, and constantly hands-on practice, the code to the end, in order to really master a programming language.

1.4.2 and Google make friends

In the development practice, it is not so much that the program is made up, rather it is "search" out. In the actual development, if you encounter a grammatical detail problem, you can use Google to search for C + + tutorials, if you encounter the function of the problem, you can use Google to search for the function of the document, if you encounter common development tasks, such as open and read a file, You can search for existing sample code with Google. Even when you encounter a program in the incurable diseases, you can also use Google search whether people encounter the same problem, see how others solve the problem. In short, programming development activities are inseparable from Google. The web is like a big gold mine, and Google is a mining machine. Using Google, and Google as friends, can help us make full use of the rich network resources to learn C + +, with good C + +.

Learn more: How to "FQ" access Google

For well-known reasons, although Google is the most useful site for every programmer, it has been unable to access it directly at home. In order to visit Google, programmers have to make a lot of trouble, some use a fee-based VPN, some use HTTP proxy as a transit, and some use the built-in "FQ" function of the special browser. These methods are either too silver or too cumbersome. A simpler and more practical approach is to first modify the system's preferred DNS server to 42.120.21.30 (the DNS server provided by the OPENERDNS project to correctly parse Google URLs), and then access the https:// www.google.com Web site, you can access Google with an encrypted HTTP protocol to avoid being blocked by a firewall for normal access to Google.

Original address: http://www.cnblogs.com/nihaoCPP/p/3936026.html

(reprint) Hello, C + + (2) 1.3 C + + world map 1.4 How to learn C + +

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.