Concat two string with most overlapped substring has to
remove  "abcd"+ "cdef" = "abcdef

Answer Posted / om

@Ashwin Kumar
According to your program....
char *a="abcdcdcd";
char *b="cdef";

output is "abcdef"..//which is wrong.....it should be abcdcdef

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the explanation for cyclic nature of data types in c?

862


Can a file other than a .h file be included with #include?

869


Why header files are used?

826


Explain the properties of union. What is the size of a union variable

916


Why do we use main function?

881


Differentiate call by value and call by reference?

740


What is static memory allocation? Explain

804


I came across some code that puts a (void) cast before each call to printf. Why?

938


Explain which function in c can be used to append a string to another string?

821


In a header file whether functions are declared or defined?

872


Can we add pointers together?

806


What is #pragma statements?

819


Can the “if” function be used in comparing strings?

768


.find the output of the following program? char*myfunc(char*ptr) { ptr +=3; return (ptr); } int main() { char*x,*y; x="HELLO"; y=myfunc(x); printf("y = %s ",y); return 0; }

2291


about c language

1790