#include<stdio.h>//header file
#include<conio.h>//header file
#include<string.h>//header file
void main() //starting of the main() function
{
int m=0,i,l,l1; //declaration of the variables
char a[10],b[20];
clrscr();
printf("program that concatenates two strings without using library function");
printf("\n\n\n\t\t------------INPUT-------------");
printf("\n\nenter the source string which has to be concatenated");
scanf("%s",&a); //taking input from the user
printf("\nenter the destination string in which the source string has to be
concatenated");
scanf("%s",&b);
l=strlen(a);
l1=strlen(b);
for(i=l1;i<l+l1;i++)
{
b[i]=a[m];
m++;
}
printf("\n\n\n\t\t------------OUTPUT------------");
printf("\n\nthe string after concatenation of the two entered strings be=%s",b);//printing
output
getch();
}