DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

index(S-osr5)


index, rindex -- string operations

Syntax

cc . . . -lc
#include <strings.h>

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

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

Description

index- character string operation

rindex- character string operation

The index function is identical to the strchr function. The rindex function is identical to the strrchr function. See string(S-osr5). index and rindex are provided for backwards compatibility: strchr and strrchr are to be recommended.

Return values

Refer to strchr and strrchr.

Diagnostics

Refer to strchr and strrchr.

See also

string(S-osr5)

Standards conformance

index and rindex are conformant with:

X/Open Portability Guide Issue 4, Version 2 (Spec-1170).


© 2005 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 -- 02 June 2005