C语言字符串连接

题目要求:

代码实现:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include<stdio.h>
#include<string.h>
void Convergence(char Array1[],char Array2[]) {
int ArrayLenOne = 0;
int ArrayLenTwo = 0;
ArrayLenOne = strlen(Array1);
ArrayLenTwo = strlen(Array2);
for (int i = 0; i < ArrayLenOne; i++) {
printf("%c", Array1[i]);
}
for (int j = 0; j < ArrayLenTwo; j++ ) {
printf("%c", Array2[j]);
}
}
int main(){
char a[200];
char b[200];
gets_s(a);
gets_s(b);
Convergence(a,b);
return 0;
}

C语言字符串连接
http://example.com/2023/08/25/C语言字符串连接/
Author
fwlw
Posted on
August 25, 2023
Licensed under