How to use C + + Primer to learn C + +?

Source: Internet
Author: User

"C + + Primer" as a prestigious C + + Classic tutorial, rich teaching aid content, well-organized programming demonstrations, whether it is beginners, or advanced programmer promotion, are undoubtedly the first choice.

A good book is only worth reading, however, "C + + Primer" This thick brick-like good book, many people in the purchase, just simply skim through the previous chapters, and not be able to seriously complete the book read.

Experimental building in order to enable everyone to better use the "C + + Primer" to learn C + +, launched in-depth study of "C + + Primer Fifth Edition" training camp, the task-driven model to learn the classic textbook, to provide a dedicated online environment, by a mentor guide all the way, lead you 7 weeks to complete the C + + Primer "Fifth edition of the study, solid your C + + foundation. And the combination of personal experience and network resources for everyone to organize a number of suggestions, share to everyone as a reference, I hope you can correctly through the "C + + Primer" Learning C + +.

How to learn "C + + Primer"?

1. "C + + Primer" This book must start from the beginning, read carefully do not jump, c++11 interspersed in every corner of the book, if you jump directly to the back you may see the new standard and return to see. And this classic book repeatedly see many times there will be a new harvest.
2. A line of the code on the book to knock over the hand, while knocking, while looking at the effect, and then think about why this, the effect is what, encountered do not understand, and then carefully in the book to find the answer, the book has a very detailed explanation. At the beginning of the code will encounter a number of grammatical errors, accumulated more can be quickly corrected.
3. Do a good study notes, the content of the book is more, and most of the content is not guaranteed to all commonly used, so some forget will be faster, so do a good study notes quickly remember themselves to see, can also be used as a tool to check leaks.

A practical reading guide from the Know

Take the fifth edition of C + + Primer as an example:

Thanks to the Netizen Canglang Shimizu in the wonderful reply, the answer link is: http://www.zhihu.com/question/32087709
    • Part1 is the first eight chapters, in addition to 6.6, 6.7, should be read through. In particular, the third chapter introduces vector and string, which is a beginner's gospel, and the two containers will be able to write some simple programs.

    • Part2 basically is the data structure and algorithm, if has the foundation to read very easily.
      9, 112 chapter introduction of the Container, and 12.1 section of the smart pointer to read through. Use smart pointers and containers, away from segment fault. The 10th chapter of the generic algorithm can be read slowly, after reading can write high-force lattice of the functional style C + +. Section 12.2 tells how to use new and delete to allocate space, the master as a novice, know this writing is OK, write the program as far as possible to replace the original array container, especially in the code is best not to have delete.

    • Part3 is a block nut, and the title is tools for Class Authors. As a "class user", some parts can be skipped for the first time.
      Chapter 13 is important, read it carefully. initialization, copying, assignment, rvalue referencing is a very subtle and important part of C + +, and other languages rarely have such a fine distinction between these concepts. This chapter should not only be intensive, but also fully mastered.
      The 14-chapter operator overloads can be seen roughly for the first time, and 14.9 sections can be skipped for the first time.
      The importance of OOP in Chapter 15 is self-evident. If the previous concept is not, learn to feel more abstract. There are many popular and interesting articles about oop that can be seen together.
      16 chapters on generic programming, first read 16.1, master the most basic function template and class template on the line.

    • PART4 is more upscale, a lot of content for the first time even gnawing down, long-term and forget. The first reading recommended to read 18.2, the namespace simple and easy to use the effect is good. Other content can be viewed in its approximate time. The 17.1-section tuple is an interesting thing to read. A regular expression of section 17.3 and a random number of 17.4 sections may be useful or read. If you need to read and write the files, you will be reading the raw I/O and 17.5.3 sections of the random I/O in the 17.5.2 section.

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

How to use C + + Primer 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.