tail head cat sleep
QR code linking to this page

manページ  — RINDEX

名称

rindex – 文字列中の文字位置の特定

内容

ライブラリ

Standard C Library (libc, -lc)

書式

#include <string.h>

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

解説

rindex() 関数は、ナル文字で終了する文字列 s から c ( char 型に変換) に一致する最後の文字位置を調べます。

戻り値

該当する文字が発見された場合、該当する文字へのポインタを返し、 見つからなかった場合は NULL を返します。 c が ‘\0’ の時、 rindex() は文字列の最後の ‘\0’ の位置を調べます。

関連項目

index(3), memchr(3), strchr(3), strcspn(3), strpbrk(3), strrchr(3), strsep(3), strspn(3), strstr(3), strtok(3)

歴史

rindex() 関数は、 AT&T v6 で登場しました。

RINDEX (3) June 4, 1993

tail head cat sleep
QR code linking to this page


このマニュアルページサービスについてのご意見は Ben Bullock にお知らせください。 Privacy policy.

“ "I liken starting one's computing career with Unix, say as an undergraduate, to being born in East Africa. It is intolerably hot, your body is covered with lice and flies, you are malnourished and you suffer from numerous curable diseases. But, as far as young East Africans can tell, this is simply the natural condition and they live within it. By the time they find out differently, it is too late. They already think that the writing of shell scripts is a natural act." ”
— Ken Pier, Xerox PARC