2014年7月19日

【STL】-function object

摘要: 1 // Generic findMax, with a function object, version #1 2 // Precondition, a.size() > 0 3 #include 4 #include 5 #include 6 using namespace std; ... 阅读全文

posted @ 2014-07-19 18:20 醉清风JM 阅读(258) 评论(0) 推荐(0)

面试题目-findmax的实现

摘要: 1 #include 2 #include 3 #include "printCollection.h" 4 5 using namespace std; 6 7 /** 8 * Return the maximum item in array a. 9 *Assume a.size(... 阅读全文

posted @ 2014-07-19 18:14 醉清风JM 阅读(398) 评论(0) 推荐(0)

c++-深拷贝

摘要: 1 //DeepCopy.cpp 2 #include 3 using namespace std; 4 5 template 6 class ObjectCell { 7 public: 8 explicit ObjectCell(object initValue ... 阅读全文

posted @ 2014-07-19 17:43 醉清风JM 阅读(197) 评论(0) 推荐(0)

导航