code for concatination of 2 strings with out using library
functions?
Answer Posted / vignesh1988i
#include<stdio.h>
#include<conio.h>
void strrcat(char *,char *);
void main()
{
char a[50],b[50];
int i;
clrscr();
printf("enter the string 1 :");
gets(a);
printf("enter the string 2 :");
gets(b);
strrcat(a,b);
gets(a);
getch();
}
void strrcat(char *a , char *b)
{
for(int i=0;*a!='\0';i++,a++);
for(int j=0;*b!='\0';j++,i++,b++,a++)
*a=*b;
*a='\0';
}
thank u :)
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is logical error?
what is different between auto and local static? why should we use local static?
What language is lisp written in?
What is the advantage of an array over individual variables?
What is difference between union and structure in c?
What is 02d in c?
write a program that will open the file, count the number of occurences of each word in the the complete works of shakespeare. You will then tabulate this information in another file.
What is structure in c explain with example?
How to compare array with pointer in c?
What is context in c?
The performance of an operation in several steps with each step using the output of the preceding step a) recursion b) search c) call by value d) call by reference
What is a double c?
illustrate the use of address operator and dereferencing operator with the help of a program guys plzzz help for this question
What does the error 'Null Pointer Assignment' mean and what causes this error?
code for quick sort?