question on rindex()

dixon at ihuxa.UUCP dixon at ihuxa.UUCP
Tue Sep 20 08:14:36 AEST 1983


Thanks to all the people who replied so quickly to my
request for info on rindex(). To summarize their replies:

    rindex() == strrchr()
    index()  == strchr().

You can use #defines to cause the appropriate function to be used. E.g,

#define index(a,b)  strchr(a,b)
#define rindex(a,b) strrchr(a,b).

Index() and rindex() were a part of V7 UNIX but dropped in later releases
of BTL UNIX.

D A Dixon      ihuxa!dixon



More information about the Comp.unix mailing list