c语言编写函数insert(char s1[ ],char s2[ ],int pos),实现在字符串s1中的指定位置pos处插入字符串s2。
c语言编写函数insert(char s1[ ],char s2[ ],int pos),实现在字符串s1中的指定位置pos处插入字符串s2。
日期:2016-10-18 17:06:50 人气:3
你写这个貌似不能实现额
用string.h库很容易实现的
要是你不能用string.h的话 你就再追问一次 我帮你把你这个改改 单貌似要改动的地方不少
#include
#include
void insert(char s1[],char s2[],int pos);
void main()
{
char s1[50],s2[50];
int pos;
gets(s1);
gets(s2);
printf("请选择要插入的位置: ");