Home / C Programming / Arrays :: Discussion

Discussion :: Arrays

  1. The library function used to find the last occurrence of a character in a string is

  2. A.

     laststr()

    B.

     strstr()

    C.

     strnstr()

    D.

     strrchr()

    E.

     None of these

    View Answer

    Workspace

    Answer : Option D

    Explanation :

    Declaration: char *strrchr(const char *s, int c);

    It scans a string s in the reverse direction, looking for a specific character c.


Be The First To Comment