strcat strncat

char * strcat ( char * destination, const char * source );

Concatenate strings
Appends a copy of the source string to the destination string. The terminating null character in destination is overwritten by the first character of source, and a new null-character is appended at the end of the new string formed by the concatenation of both in destination.

 

 

char * strncat ( char * destination, char * source, size_t num );

Append characters from string
Appends the first num characters of source to destination, plus a terminating null-character. If the length of the C string in source is less than num, only the content up to the terminating null-character is copied.

posted @ 2011-10-23 16:37  greencolor  阅读(282)  评论(0编辑  收藏  举报