#define MAXSIZE 256
typedef struct
{ char data[MAXSIZE];
int curlen;
} SeqString;
int StrLength(SeqString *s)
{ int x=0;
while(s->data[x]!='/0')
x++;
return x;}
int StrConcat1(s1,s2,s)
char s1[ ],s2[ ],s[ ];
{ int i=0 , j, len1, len2;
len1= StrLength(s1); len2= StrLength(s2);
if (len1+ len2>MAXSIZE-1) return 0 ; /* s长度不够*/
j=0;
while(s1[j]!='/0')
{ s[i]=s1[j]; i++; j++; }
j=0;
while(s2[j]!='/0')
{ s[i]=s2[j]; i++; j++; }
s[i]='/0';
return 1;
}
main()
{char a[256]="abc",b[222]="xyz",c[300];
StrConcat1(a,b,c);
puts(c);
}