Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Zortech C++ 3.0r4 - <b>strchr</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
strchr

Usage

   #include <string.h>
   char *strchr(const char *string,int ch);

   ANSI

Description

   Finds the first occurrence of the character ch in string. It returns a
   pointer to character ch. strchr is identical to the function index.

Example 

   #include <stdio.h>
   #include <string.h>
   #include <stdlib.h>

   char string1[50] = " 1 Example string ";

   int main()
   {
       printf("\nstrchr example [%s]\n",
               strchr(string1,'2'));
       return EXIT_SUCCESS;
   }

Return Value

   Pointer to character ch. A NULL pointer is returned if not found.

See Also

   memchr



See Also: memchr

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson