删除重复定义的算法find

This commit is contained in:
邹晓航
2014-10-20 11:15:26 +08:00
parent a3281b8e22
commit 5774787893

View File

@@ -41,16 +41,6 @@ namespace TinySTL{
memset(first, static_cast<unsigned char>(value), n * sizeof(wchar_t));
return first + n;
}
//************ [find] ****************
//********* [Algorithm Complexity: O(N)] ****************
template<class InputIterator, class T>
InputIterator find(InputIterator first, InputIterator last, const T& val){
for (; first != last; ++first){
if (*first == val)
break;
}
return first;
}
//*********** [min] ********************
//********* [Algorithm Complexity: O(1)] ****************
template <class T>