strchr returns a zero-based index to the last occurrence of char in string. If char is not found NULL is returned. char can be given either as an integer ASCII value or a string, in which case the first character of that string is searched for in str.
strchr('AbracadabrA','A') -> 0 (Found as the first character). strrchr('AbracadabrA',65) -> 10 (Found as the eleventh character)