...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
boost::algorithm::is_palindrome
// In header: <boost/algorithm/is_palindrome.hpp> template<typename BidirectionalIterator, typename Predicate> bool is_palindrome(BidirectionalIterator begin, BidirectionalIterator end, Predicate p);
Note | |
---|---|
This function will return true for empty sequences and for palindromes. For other sequences function will return false. Complexity: O(N). |
Parameters: |
|
||||||
Returns: |
true if the entire sequence is palindrome |