权威 C++ 书籍指南和列表
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/388242/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
The Definitive C++ Book Guide and List
提问by grepsedawk
This question attempts to collect the few pearls among the dozens of bad C++ books that are published every year.
这个问题试图收集每年出版的几十本糟糕的 C++ 书籍中的少数珍珠。
Unlike many other programming languages, which are often picked up on the go from tutorials found on the Internet, few are able to quickly pick up C++ without studying a well-written C++ book. It is way too big and complex for doing this. In fact, it is so big and complex, that there are very many very bad C++ booksout there. And we are not talking about bad style, but things like sporting glaringly obvious factual errorsand promoting abysmally bad programming styles.
与许多其他编程语言(经常从 Internet 上的教程中学习)不同,很少有人能够在不学习精心编写的 C++ 书籍的情况下快速掌握 C++。这样做太庞大和复杂了。事实上,它是如此庞大和复杂,以至于有很多非常糟糕的 C++ 书籍。我们不是在谈论糟糕的风格,而是在谈论明显的事实错误和宣传极坏的编程风格。
Please edit the accepted answer to provide quality booksand an approximate skill level — preferablyafterdiscussing your addition in the C++ chat room. (The regulars might mercilessly undo your work if they disagree with a recommendation.) Add a short blurb/description about each book that you have personally read/benefited from. Feel free to debate quality, headings, etc. Books that meet the criteria will be added to the list. Books that have reviews by the Association of C and C++ Users (ACCU) have links to the review.
请编辑接受的答案以提供高质量的书籍和大致的技能水平 -最好在C++ 聊天室中讨论您的补充之后。(如果他们不同意推荐,常客可能会无情地撤消您的工作。)为您个人阅读/受益的每本书添加简短的简介/描述。随意讨论质量、标题等。符合标准的书籍将被添加到列表中。有 C 和 C++ 用户协会 (ACCU) 评论的书籍有评论链接。
*Note: FAQs and other resources can be found in the C++ tag infoand under c++-faq.
*注意:常见问题解答和其他资源可以在C++ 标签信息和c++-faq 下找到。
回答by Johannes Schaub - litb
Beginner
初学者
Introductory, no previous programming experience
入门,无编程经验
C++ Primer* (Stanley Lippman, Josée Lajoie, and Barbara E. Moo) (updated for C++11) Coming at 1k pages, this is a very thorough introduction into C++ that covers just about everything in the language in a very accessible format and in great detail. The fifth edition (released August 16, 2012) covers C++11. [Review]
Programming: Principles and Practice Using C++(Bjarne Stroustrup, 2nd Edition - May 25, 2014) (updated for C++11/C++14) An introduction to programming using C++ by the creator of the language. A good read, that assumes no previous programming experience, but is not only for beginners.
C++ Primer*(Stanley Lippman、Josée Lajoie 和 Barbara E. Moo)(针对 C++11 进行了更新) 共有 1k 页,这是对 C++ 的非常全面的介绍,以一种非常易于访问的格式涵盖了该语言中的几乎所有内容并且非常详细。第五版(2012 年 8 月 16 日发布)涵盖 C++11。[]
编程:使用 C++ 的原则和实践(Bjarne Stroustrup,第 2 版 - 2014 年 5 月 25 日)(针对 C++11/C++14 更新)该语言的创建者对使用 C++ 进行编程的介绍。一本很好的读物,它假设没有以前的编程经验,但不仅适合初学者。
* Not to be confused with C++ Primer Plus(Stephen Prata), with a significantly less favorable review.
*不要与混淆C ++的Primer Plus(斯蒂芬·普拉塔),有显著不太有利的评论。
Introductory, with previous programming experience
入门,有编程经验
A Tour of C++(Bjarne Stroustrup) (2nd edition for C++17) The “tour” is a quick (about 180 pages and 14 chapters) tutorial overview of all of standard C++ (language and standard library, and using C++11) at a moderately high level for people who already know C++ or at least are experienced programmers. This book is an extended version of the material that constitutes Chapters 2-5 of The C++ Programming Language, 4th edition.
Accelerated C++(Andrew Koenig and Barbara Moo, 1st Edition - August 24, 2000) This basically covers the same ground as the C++ Primer, but does so on a fourth of its space. This is largely because it does not attempt to be an introduction to programming, but an introduction to C++for people who've previously programmed in some other language. It has a steeper learning curve, but, for those who can cope with this, it is a very compact introduction to the language. (Historically, it broke new ground by being the first beginner's book to use a modern approach to teaching the language.) Despite this, the C++ it teaches is purely C++98. [Review]
C++ 之旅(Bjarne Stroustrup)(C++17 的第 2 版) “之旅”是对所有标准 C++(语言和标准库,以及使用 C++)的快速(大约 180 页和 14 章)教程概述11) 对于已经了解 C++ 或至少是有经验的程序员的人来说,处于中等高水平。本书是构成 The C++ Programming Language 第 4 版第 2-5 章材料的扩展版本。
Accelerated C++(Andrew Koenig 和 Barbara Moo,第 1 版 - 2000 年 8 月 24 日)这基本上涵盖了与C++ Primer 相同的内容,但只占其四分之一的篇幅。这主要是因为它并不试图成为编程的介绍,而是为以前使用其他语言编程的人介绍C++。它有一个更陡峭的学习曲线,但是,对于那些能够应付这个问题的人来说,这是对这门语言的一个非常紧凑的介绍。(从历史上看,它开辟了新天地,是第一本使用现代方法教授语言的初学者书籍。)尽管如此,它教授的 C++ 是纯粹的 C++98。[]
Best practices
最佳实践
Effective C++(Scott Meyers, 3rd Edition - May 22, 2005) This was written with the aim of being the best second book C++ programmers should read, and it succeeded. Earlier editions were aimed at programmers coming from C, the third edition changes this and targets programmers coming from languages like Java. It presents ~50 easy-to-remember rules of thumb along with their rationale in a very accessible (and enjoyable) style. For C++11 and C++14 the examples and a few issues are outdated and Effective Modern C++ should be preferred. [Review]
Effective Modern C++(Scott Meyers) This is basically the new version of Effective C++, aimed at C++ programmers making the transition from C++03 to C++11 and C++14.
- Effective STL(Scott Meyers) This aims to do the same to the part of the standard library coming from the STL what Effective C++did to the language as a whole: It presents rules of thumb along with their rationale. [Review]
Effective C++(Scott Meyers,第 3 版 - 2005 年 5 月 22 日)这本书的目的是成为 C++ 程序员应该阅读的最好的第二本书,它成功了。早期版本针对来自 C 的程序员,第三版改变了这一点并针对来自 Java 等语言的程序员。它以一种非常容易理解(和令人愉快)的方式呈现了大约 50 条易于记忆的经验法则及其基本原理。对于 C++11 和 C++14,示例和一些问题已经过时,应首选有效的现代 C++。[]
Effective Modern C++(Scott Meyers) 这基本上是Effective C++的新版本,针对 C++ 程序员从 C++03 过渡到 C++11 和 C++14。
- Effective STL(Scott Meyers) 这旨在对来自 STL 的标准库部分做同样的事情,就像Effective C++对整个语言所做的一样:它提出了经验法则及其基本原理。[]
Intermediate
中间的
More Effective C++(Scott Meyers) Even more rules of thumb than Effective C++. Not as important as the ones in the first book, but still good to know.
Exceptional C++(Herb Sutter) Presented as a set of puzzles, this has one of the best and thorough discussions of the proper resource management and exception safety in C++ through Resource Acquisition is Initialization (RAII) in addition to in-depth coverage of a variety of other topics including the pimpl idiom, name lookup, good class design, and the C++ memory model. [Review]
More Exceptional C++(Herb Sutter) Covers additional exception safety topics not covered in Exceptional C++, in addition to discussion of effective object-oriented programming in C++ and correct use of the STL. [Review]
Exceptional C++ Style(Herb Sutter) Discusses generic programming, optimization, and resource management; this book also has an excellent exposition of how to write modular code in C++ by using non-member functions and the single responsibility principle. [Review]
C++ Coding Standards(Herb Sutter and Andrei Alexandrescu) “Coding standards” here doesn't mean “how many spaces should I indent my code?” This book contains 101 best practices, idioms, and common pitfalls that can help you to write correct, understandable, and efficient C++ code. [Review]
C++ Templates: The Complete Guide(David Vandevoorde and Nicolai M. Josuttis) This is thebook about templates as they existed before C++11. It covers everything from the very basics to some of the most advanced template metaprogramming and explains every detail of how templates work (both conceptually and at how they are implemented) and discusses many common pitfalls. Has excellent summaries of the One Definition Rule (ODR) and overload resolution in the appendices. A second editioncovering C++11, C++14 and C++17 has been already published. [Review]
C++ 17 - The Complete Guide(Nicolai M. Josuttis) This book describes all the new features introduced in the C++17 Standard covering everything from the simple ones like 'Inline Variables', 'constexpr if' all the way up to 'Polymorphic Memory Resources' and 'New and Delete with overaligned Data'.
More Effective C++(Scott Meyers) 比Effective C++更多的经验法则。不如第一本书中的重要,但还是很高兴知道。
Exceptional C++(Herb Sutter) 以一组谜题的形式呈现,除了深入涵盖各种内容之外,还通过资源获取是初始化 (RAII) 对 C++ 中的适当资源管理和异常安全进行了最好和彻底的讨论。其他主题包括 pimpl 成语、名称查找、良好的类设计和 C++ 内存模型。[]
More Exceptional C++(Herb Sutter) 除了讨论C++中有效的面向对象编程和正确使用 STL 之外,还涵盖了Exceptional C++ 中未涵盖的其他异常安全主题。[]
Exceptional C++ Style(Herb Sutter) 讨论泛型编程、优化和资源管理;本书还很好地阐述了如何使用非成员函数和单一职责原则在 C++ 中编写模块化代码。[]
C++ 编码标准(Herb Sutter 和 Andrei Alexandrescu) 这里的“编码标准”并不意味着“我应该缩进多少个空格?” 本书包含 101 个最佳实践、习惯用法和常见陷阱,可帮助您编写正确、易懂且高效的 C++ 代码。[]
C++ 模板:完整指南(David Vandevoorde 和 Nicolai M. Josuttis) 这是一本关于 C++11 之前存在的模板的书。它涵盖了从非常基础到一些最高级的模板元编程的所有内容,并解释了模板如何工作的每个细节(概念上和实现方式),并讨论了许多常见的陷阱。在附录中对单一定义规则 (ODR) 和重载解析进行了出色的总结。涵盖 C++11、C++14 和 C++17的第二版已经出版。[]
C++ 17 - 完整指南(Nicolai M. Josuttis) 这本书描述了 C++17 标准中引入的所有新特性,涵盖了从简单的像“内联变量”、“constexpr if”到“多态”的所有内容内存资源”和“使用过度对齐的数据新建和删除”。
Advanced
先进的
Modern C++ Design(Andrei Alexandrescu) A groundbreaking book on advanced generic programming techniques. Introduces policy-based design, type lists, and fundamental generic programming idioms then explains how many useful design patterns (including small object allocators, functors, factories, visitors, and multi-methods) can be implemented efficiently, modularly, and cleanly using generic programming. [Review]
C++ Template Metaprogramming(David Abrahams and Aleksey Gurtovoy)
C++ Concurrency In Action(Anthony Williams) A book covering C++11 concurrency support including the thread library, the atomics library, the C++ memory model, locks and mutexes, as well as issues of designing and debugging multithreaded applications. A second editioncovering C++14 and C++17 has been already published.
Advanced C++ Metaprogramming(Davide Di Gennaro) A pre-C++11 manual of TMP techniques, focused more on practice than theory. There are a ton of snippets in this book, some of which are made obsolete by type traits, but the techniques, are nonetheless useful to know. If you can put up with the quirky formatting/editing, it is easier to read than Alexandrescu, and arguably, more rewarding. For more experienced developers, there is a good chance that you may pick up something about a dark corner of C++ (a quirk) that usually only comes about through extensive experience.
Functional Programming in C++(Ivan ?uki?) The book introduces the reader to the functional paradigm in modern C++. It covers the theoretical and code aspects with a variety of examples and diagrams. The author has experience in teaching and uses it to smoothly guide the reader through different aspects of functional programming.
Modern C++ Design(Andrei Alexandrescu) 一本关于高级泛型编程技术的开创性书籍。介绍基于策略的设计、类型列表和基本的泛型编程习语,然后解释使用泛型编程可以高效、模块化和干净地实现多少有用的设计模式(包括小对象分配器、函子、工厂、访问者和多方法) . []
C++ 模板元编程(David Abrahams 和 Aleksey Gurtovoy)
C++ Concurrency In Action(Anthony Williams) 一本涵盖 C++11 并发支持的书,包括线程库、原子库、C++ 内存模型、锁和互斥锁,以及设计和调试多线程应用程序的问题。涵盖 C++14 和 C++17的第二版已经出版。
Advanced C++ Metaprogramming(Davide Di Gennaro) C++11 之前的 TMP 技术手册,更侧重于实践而非理论。本书中有大量片段,其中一些片段因类型特征而过时,但了解这些技术仍然很有用。如果你能忍受古怪的格式/编辑,它比 Alexandrescu 更容易阅读,而且可以说,更有价值。对于更有经验的开发人员,您很有可能会从 C++ 的阴暗角落(一个怪癖)中了解到一些通常只有通过丰富经验才能获得的东西。
C++ 中的函数式编程(Ivan ?uki?) 这本书向读者介绍了现代 C++ 中的函数范式。它通过各种示例和图表涵盖了理论和代码方面。作者有教学经验,并用它来顺利引导读者了解函数式编程的不同方面。
Reference Style - All Levels
参考样式 - 所有级别
The C++ Programming Language(Bjarne Stroustrup) (updated for C++11) The classic introduction to C++ by its creator. Written to parallel the classic K&R, this indeed reads very much like it and covers just about everything from the core language to the standard library, to programming paradigms to the language's philosophy. [Review]Note: All releases of the C++ standard are tracked in this question: Where do I find the current C++ standard.
C++ Standard Library Tutorial and Reference(Nicolai Josuttis) (updated for C++11) Theintroduction and reference for the C++ Standard Library. The second edition (released on April 9, 2012) covers C++11. [Review]
The C++ IO Streams and Locales(Angelika Langer and Klaus Kreft) There's very little to say about this book except that, if you want to know anything about streams and locales, then this is the one place to find definitive answers. [Review]
C++ 编程语言(Bjarne Stroustrup)(针对 C++11 进行了更新) 其创建者对 C++ 的经典介绍。与经典的 K&R 并行编写,这确实读起来非常像它,涵盖了从核心语言到标准库,从编程范式到语言哲学的所有内容。[评论]注意:在此问题中跟踪了 C++ 标准的所有版本:我在哪里可以找到当前的 C++ 标准。
C++ 标准库教程和参考(Nicolai Josuttis)(针对 C++11 更新)C++ 标准库的介绍和参考。第二版(2012 年 4 月 9 日发布)涵盖 C++11。[]
C++ IO 流和区域设置(Angelika Langer 和 Klaus Kreft) 关于这本书几乎没有什么可说的,除了如果您想了解有关流和区域设置的任何信息,那么这是一个可以找到明确答案的地方。[]
C++11/14/17/… References:
C++11/14/17/... 参考资料:
The C++11/14/17Standard (INCITS/ISO/IEC 14882:2011/2014/2017)This, of course, is the final arbiter of all that is or isn't C++. Be aware, however, that it is intended purely as a reference for experiencedusers willing to devote considerable time and effort to its understanding. The C++17 standard is released in electronic form for 198 Swiss Francs.
The C++17 standard is available, but seemingly not in an economical form – directly from the ISOit costs 198 Swiss Francs (about $200 US). For most people, the final draft before standardizationis more than adequate (and free). Many will prefer an even newer draft, documenting new features that are likely to be included in C++20.
Overview of the New C++ (C++11/14) (PDF only)(Scott Meyers) (updated for C++14) These are the presentation materials (slides and some lecture notes) of a three-day training course offered by Scott Meyers, who's a highly respected author on C++. Even though the list of items is short, the quality is high.
The C++ Core Guidelines (C++11/14/17/…)(edited by Bjarne Stroustrup and Herb Sutter) is an evolving online document consisting of a set of guidelines for using modern C++ well. The guidelines are focused on relatively higher-level issues, such as interfaces, resource management, memory management and concurrency affecting application architecture and library design. The project was announced at CppCon'15 by Bjarne Stroustrup and othersand welcomes contributions from the community. Most guidelines are supplemented with a rationale and examples as well as discussions of possible tool support. Many rules are designed specifically to be automatically checkable by static analysis tools.
The C++ Super-FAQ(Marshall Cline, Bjarne Stroustrup and others) is an effort by the Standard C++ Foundation to unify the C++ FAQs previously maintained individually by Marshall Cline and Bjarne Stroustrup and also incorporating new contributions. The items mostly address issues at an intermediate level and are often written with a humorous tone. Not all items might be fully up to date with the latest edition of the C++ standard yet.
cppreference.com (C++03/11/14/17/…)(initiated by Nate Kohl) is a wiki that summarizes the basic core-language features and has extensive documentation of the C++ standard library. The documentation is very precise but is easier to read than the official standard document and provides better navigation due to its wiki nature. The project documents all versions of the C++ standard and the site allows filtering the display for a specific version. The project was presented by Nate Kohl at CppCon'14.
C++ 11/ 14/ 17标准 (INCITS/ISO/IEC 14882:2011/2014/2017)这当然是所有 C++ 的最终仲裁者。但是请注意,它仅用作愿意投入大量时间和精力来理解它的有经验的用户的参考。C++17 标准以电子形式发布,价格为 198 瑞士法郎。
C++17 标准是可用的,但似乎不是一种经济的形式——直接从 ISO那里花费 198 瑞士法郎(约 200 美元)。对于大多数人来说,标准化之前的最终草案绰绰有余(而且免费)。许多人更喜欢更新的草稿,记录可能包含在 C++20 中的新功能。
新 C++ 概述 (C++11/14)(仅 PDF)(Scott Meyers)(针对 C++14 更新)这些是由以下机构提供的为期三天的培训课程的演示材料(幻灯片和一些讲义) Scott Meyers,他是一位备受尊敬的 C++ 作家。尽管项目清单很短,但质量很高。
在C ++核心准则(C ++ 11/14/17 / ...) (由Bjarne Stroustrup的和香草萨特编辑)是由一组准则的使用现代C ++以及一个不断发展的在线文档。这些指南侧重于相对较高级别的问题,例如接口、资源管理、内存管理和影响应用程序架构和库设计的并发性。该项目由 Bjarne Stroustrup 和其他人在 CppCon'15 上宣布,并欢迎社区的贡献。大多数指南都补充有基本原理和示例以及对可能的工具支持的讨论。许多规则专门设计为可由静态分析工具自动检查。
在C ++超级FAQ(马歇尔克莱因,Bjarne的Stroustrup的和其他人)是由标准C ++基金会努力统一C ++常见问题以前由马歇尔克莱因和Bjarne的Stroustrup的单独维护,并纳入新的贡献。这些项目主要解决中级问题,并且通常以幽默的语气编写。并非所有项目都可能与最新版本的 C++ 标准完全同步。
cppreference.com (C++03/11/14/17/...)(由 Nate Kohl 发起)是一个 wiki,它总结了基本的核心语言特性,并拥有 C++ 标准库的大量文档。该文档非常精确,但比官方标准文档更易于阅读,并且由于其 wiki 性质提供了更好的导航。该项目记录了 C++ 标准的所有版本,并且该站点允许过滤特定版本的显示。该项目由 Nate Kohl 在 CppCon'14 上提出。
Classics / Older
经典 / 老
Note:Some information contained within these books may not be up-to-date or no longer considered best practice.
注意:这些书中包含的某些信息可能不是最新的或不再被视为最佳实践。
The Design and Evolution of C++(Bjarne Stroustrup) If you want to know whythe language is the way it is, this book is where you find answers. This covers everything before the standardizationof C++.
Ruminations on C++- (Andrew Koenig and Barbara Moo) [Review]
Advanced C++ Programming Styles and Idioms(James Coplien) A predecessor of the pattern movement, it describes many C++-specific “idioms”. It's certainly a very good book and might still be worth a read if you can spare the time, but quite old and not up-to-date with current C++.
Large Scale C++ Software Design(John Lakos) Lakos explains techniques to manage very big C++ software projects. Certainly, a good read, if it only was up to date. It was written long before C++ 98 and misses on many features (e.g. namespaces) important for large-scale projects. If you need to work in a big C++ software project, you might want to read it, although you need to take more than a grain of salt with it. The first volume of a new edition is released in 2019.
Inside the C++ Object Model(Stanley Lippman) If you want to know how virtual member functions are commonly implemented and how base objects are commonly laid out in memory in a multi-inheritance scenario, and how all this affects performance, this is where you will find thorough discussions of such topics.
The Annotated C++ Reference Manual(Bjarne Stroustrup, Margaret A. Ellis) This book is quite outdated in the fact that it explores the 1989 C++ 2.0 version - Templates, exceptions, namespaces and new casts were not yet introduced. Saying that however, this book goes through the entire C++ standard of the time explaining the rationale, the possible implementations, and features of the language. This is not a book to learn programming principles and patterns on C++, but to understand every aspect of the C++ language.
Thinking in C++(Bruce Eckel, 2nd Edition, 2000). Two volumes; is a tutorial style freeset of intro level books. Downloads: vol 1, vol 2. Unfortunately they’re marred by a number of trivial errors (e.g. maintaining that temporaries are automatically
const
), with no official errata list. A partial 3rdparty errata list is available at (http://www.computersciencelab.com/Eckel.htm), but it’s apparently not maintained.Scientific and Engineering C++: An Introduction to Advanced Techniques and Examples(John Barton and Lee Nackman) It is a comprehensive and very detailed book that tried to explain and make use of all the features available in C++, in the context of numerical methods. It introduced at the time several new techniques, such as the Curiously Recurring Template Pattern (CRTP, also called Barton-Nackman trick). It pioneered several techniques such as dimensional analysis and automatic differentiation. It came with a lot of compilable and useful code, ranging from an expression parser to a Lapack wrapper. The code is still available here: http://www.informit.com/store/scientific-and-engineering-c-plus-plus-an-introduction-9780201533934. Unfortunately, the books have become somewhat outdated in the style and C++ features, however, it was an incredible tour-de-force at the time (1994, pre-STL). The chapters on dynamics inheritance are a bit complicated to understand and not very useful. An updated version of this classic book that includes move semantics and the lessons learned from the STL would be very nice.
C++ 的设计和演化(Bjarne Stroustrup) 如果你想知道为什么这种语言是这样的,这本书就是你找到答案的地方。这涵盖了 C++标准化之前的所有内容。
Advanced C++ Programming Styles and Idioms(James Coplien) 模式运动的前身,它描述了许多 C++ 特定的“习语”。这当然是一本非常好的书,如果您能抽出时间,可能仍然值得一读,但它很旧,并且与当前的 C++ 不同步。
大型 C++ 软件设计(John Lakos) Lakos 解释了管理大型 C++ 软件项目的技术。当然,如果它只是最新的,那么很好读。它早在 C++ 98 之前编写,并且遗漏了许多对大型项目很重要的特性(例如命名空间)。如果您需要在大型 C++ 软件项目中工作,您可能想要阅读它,尽管您需要对它采取更多的措施。新版本的第一卷于2019年发布。
C++ 对象模型内部(Stanley Lippman) 如果您想了解虚成员函数是如何普遍实现的,基对象在多继承场景中通常如何在内存中布局,以及所有这些如何影响性能,这就是您要了解的地方找到有关此类主题的深入讨论。
带注释的 C++ 参考手册(Bjarne Stroustrup, Margaret A. Ellis) 这本书已经过时了,因为它探索了 1989 C++ 2.0 版本 - 模板、异常、命名空间和新的强制转换尚未引入。然而,这本书贯穿了当时整个 C++ 标准,解释了该语言的基本原理、可能的实现和特性。这不是一本学习 C++ 编程原理和模式的书,而是了解 C++ 语言的方方面面。
用 C++ 思考(Bruce Eckel,第 2 版,2000 年)。两卷;是一套教程风格的免费入门级书籍。下载:第 1卷,第 2 卷。不幸的是,它们被一些小错误所破坏(例如,保持临时表是自动的
const
),没有官方勘误表。的部分3次方勘误表可在(http://www.computersciencelab.com/Eckel.htm),但它显然不能维持。Scientific and Engineering C++: An Introduction to Advanced Techniques and Examples(John Barton 和 Lee Nackman) 这是一本全面且非常详细的书,试图在数值方法的上下文中解释和利用 C++ 中的所有可用功能。它当时引入了几种新技术,例如 Curiously Recurring Template Pattern(CRTP,也称为 Barton-Nackman 技巧)。它开创了多项技术,如尺寸分析和自动微分。它附带了许多可编译且有用的代码,从表达式解析器到 Lapack 包装器。该代码仍然可用:http://www.informit.com/store/scientific-and-engineering-c-plus-plus-an-introduction-9780201533934. 不幸的是,这些书在风格和 C++ 功能方面已经有些过时了,但是,它在当时是一个令人难以置信的巡回演出(1994 年,STL 之前)。关于动态继承的章节理解起来有点复杂,也不是很有用。这本经典书籍的更新版本包括移动语义和从 STL 中学到的经验教训会非常好。