| 3182 | namespace Detail { |
| 3183 | template <typename InputIterator, typename T> |
| 3184 | size_t count(InputIterator first, InputIterator last, T const& item) { |
| 3185 | size_t cnt = 0; |
| 3186 | for (; first != last; ++first) { |
| 3187 | if (*first == item) { |
| 3188 | ++cnt; |
| 3189 | } |
| 3190 | } |
| 3191 | return cnt; |
| 3192 | } |
| 3193 | template <typename InputIterator, typename T> |
| 3194 | bool contains(InputIterator first, InputIterator last, T const& item) { |
| 3195 | for (; first != last; ++first) { |