ref: 16ea0054046e540a90a8a44fd81c0f7b4ae8024d dir: /lib/c/strrchr.c/
#include <string.h> #undef strrchr char * strrchr(const char *s, int c) { const char *t = s; while (*t) ++t; while (t > s && *t != c) --t; return (*t == c) ? (char *)t : NULL; }