algorithms/ adjacentfind.bi | |
License | Copyright © 2009, FreeBASIC Extended Library Development Group |
Functions | |
AdjacentFind | Finds the first of two consecutive elements in the range [first, last) that compare equal to each other using operator =. |
AdjacentFind | Finds the first of two consecutive elements in the range [first, last) that satisfy the predicate pred. |
Copyright © 2009, FreeBASIC Extended Library Development Group
Distributed under the FreeBASIC Extended Library Group license. See accompanying file LICENSE.txt or copy at http://code.google.com- /p- /fb-extended-lib- /wiki- /License
declare function AdjacentFind overload ( byval first as fbext_TypeName(T_) ptr, byval last as fbext_TypeName(T_) ptr ) as fbext_TypeName(T_) ptr
Finds the first of two consecutive elements in the range [first, last) that compare equal to each other using operator =.
first | A pointer to the first element in the range to search. |
last | A pointer one-past the element in the range to search. |
Returns a pointer to the element found, or last if there is no such element.
declare function AdjacentFind ( byval first as fbext_TypeName(T_) ptr, byval last as fbext_TypeName(T_) ptr, byval pred as function ( byref as const fbext_TypeName(T_), byref as const fbext_TypeName(T_) ) as ext.bool ) as fbext_TypeName(T_) ptr
Finds the first of two consecutive elements in the range [first, last) that satisfy the predicate pred.
first | A pointer to the first element in the range to search. |
last | A pointer one-past the element in the range to search. |
pred | The BinaryPredicate function to call. |
Returns a pointer to the element found, or last if there is no such element.
Finds the first of two consecutive elements in the range [first, last) that compare equal to each other using operator =.
declare function AdjacentFind overload ( byval first as fbext_TypeName(T_) ptr, byval last as fbext_TypeName(T_) ptr ) as fbext_TypeName(T_) ptr