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>strncat</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
strncat

Usage

   #include <string.h>
   char *strncat(char *string1, const char *string2, size_t n);

   ANSI

Description

   Appends the lesser of n or strlen(string2) characters of string2 onto the
   end of string1 and adds a terminating null  \0'. It is the user's
   responsibility to ensure there is enough space in string1 to hold the
   result.

Example 

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

   char string[50] = " Example string";
   char *string2 = " Add this string";

   int main()
   {
       printf("strncat Example [%s]\n",
               strncat(string,string2,50));
       return EXIT_SUCCESS;
   }

Return Value

   It returns string1.

See Also

   strcat



See Also: strcat

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