To avoid resource leaks
when you have containers of pointers that should be deleted, you must either replace
the pointers with smart reference-counting pointer objects (such as Boost's shared_ptr)
or you must manually delete each pointer in the container before the container is
destroyed. (查看原文)
重点: item 1, 5, 9, 14, 18, 24, 28, 31 Item 5. Prefer range member functions to their single-element counterparts. Item 9. eg: container.erase(remove(c.begin(), c.end(), target), c.end()); (1) To eliminate all objects in a container that have a particular ...
(展开)
0 有用 Kevin Lee 2010-01-25 15:23:02
泛型
0 有用 介错 2013-03-25 21:56:33
各种坑
0 有用 陈小奈 2009-11-17 17:06:12
首先声明,这绝对是一本好事,但是我现在要矜持,不能轻易的打5星,呵呵。我的stl经验只是使用容器和迭代器而已,算法很少用,函数对象根本没用过,更高级点的只是知道有那会是而已。以后争取在项目中多用点高级功能,也不枉看过此书。
0 有用 squalfof 2013-09-17 07:44:32
在参与项目的过程中翻看此书,收获颇丰。 纸上得来终觉浅,绝知此事要躬行。
0 有用 squalfof 2013-09-17 07:44:32
在参与项目的过程中翻看此书,收获颇丰。 纸上得来终觉浅,绝知此事要躬行。
0 有用 介错 2013-03-25 21:56:33
各种坑
0 有用 Kevin Lee 2010-01-25 15:23:02
泛型
0 有用 陈小奈 2009-11-17 17:06:12
首先声明,这绝对是一本好事,但是我现在要矜持,不能轻易的打5星,呵呵。我的stl经验只是使用容器和迭代器而已,算法很少用,函数对象根本没用过,更高级点的只是知道有那会是而已。以后争取在项目中多用点高级功能,也不枉看过此书。