DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

index(S)


index -- string operations

Synopsis

   #include <strings.h>
   

char *index(const char *s, int c);

char *rindex(const char *s, int c);

Description

rindex- string operations

These functions operate on NULL-terminated strings. They do not check for overflow of any receiving string.

index and rindex return a pointer to the first (last) occurrence of character c in string s, or a NULL pointer if c does not occur in the string. The NULL character terminating a string is considered to be part of the string.

References

bstring(S), malloc(S), string(S), string(S)

Notices

For user convenience, these functions are declared in the optional <strings.h> header file.
© 2005 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 - 01 June 2005