Query: bsearch
OS: osf1
Section: 3
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
bsearch(3) Library Functions Manual bsearch(3)NAMEbsearch - Performs a binary searchLIBRARYStandard C Library (libc)SYNOPSIS#include <stdlib.h> void *bsearch( const void *key, const void *base, size_t nmemb, size_t size, int (*compar)(const void *, const void *));STANDARDSInterfaces documented on this reference page conform to industry standards as follows: bsearch(): XSH5.0 Refer to the standards(5) reference page for more information about industry standards and associated tags.PARAMETERSTarget of search. Points to the initial object in the array. Specifies the number of elements in the array. Specifies the byte size of each element of the array. Points to the comparison function, which is called with two parameters that point to the key object and to an array member, in that order.DESCRIPTIONThe bsearch() function does a binary search and returns a pointer in an array that indicates where an object is found. The compar comparison function is called with two parameters that point to objects that are compared during the search. This function returns an integer less than, equal to, or greater than 0 (zero) depending whether the object pointed to by the key parameter is considered to be less than, equal to, or greater than the array element.NOTES[Tru64 UNIX] The bsearch() function is reentrant, but care should be taken to ensure that the function supplied as argument compar is also reentrant.RETURN VALUESUpon successful completion, the bsearch() function returns a pointer to a matching object in the array. A NULL is returned when no match is found. When two or more objects compare equally, the returned object is unspecified.RELATED INFORMATIONFunctions: hsearch(3), lsearch(3), qsort(3), tsearch(3) Standards: standards(5) delim off bsearch(3)
Related Man Pages |
---|
bsearch(3) - linux |
bsearch(3c) - sunos |
bsearch(3c) - hpux |
lsearch(3) - osf1 |
bsearch(3) - opendarwin |
Similar Topics in the Unix Linux Community |
---|
OBSearch 0.9.1b (Default branch) |
Jaeksoft WebSearch 0.2 |
Jaeksoft WebSearch 0.2 |
Jaeksoft WebSearch 0.3 |
Jaeksoft WebSearch 0.3 |