moringwind 发表于 2006-12-18 10:37:12

lw如何合并字符串?

如题。比如
#define A="123"
int      b=4;
char      strB;
Fmt(strB, %s<%i, b);
合并A和strB,把strB加入到A的后面。

cpubbs 发表于 2006-12-18 21:11:20

用这个函数可以:
This function appends a copy of a source string (including the terminating ASCII NUL byte) to the end of a target string.The initial character of the string to append overwrites the NUL byte at the end of the target string.If copying takes place between objects that overlap, the behavior is undefined.

/*-------------------- Prototype ---------------------*/
char *strcat (char Target_String[],
            const char String_to_Append[]);

yufuwan 发表于 2007-2-4 03:41:35

这个应该是c的函数吧~~~直接用就行了
页: [1]
查看完整版本: lw如何合并字符串?