Look at the Code:
#include<string.h>
void main()
{
char s1[]="abcd";
char s2[10];
char s3[]="efgh";
int i;
clrscr();
i=strcmp(strcat(s3,ctrcpy(s2,s1))strcat(s3,"abcd"));
printf("%d",i);
}

What will be the output?
A)No output B) A Non Integer C)0 D) Garbage

Answer Posted / santhoo035

if u write the write the code as i=strcmp(strcat(s3,ctrcpy
(s2,s1)),strcat(s3,"abcd")); then it will print 0

Is This Answer Correct ?    4 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how can you tell whether two strings are the same?

582


Difference between pass by reference and pass by value?

658


Why we use break in c?

550


What is the role of && operator in a program code?

568


Can we increase size of array in c?

542






Why c is called free form language?

570


How is pointer initialized in c?

585


How can I manipulate strings of multibyte characters?

639


What is meant by realloc()?

676


What is a null pointer in c?

595


What is typedef struct in c?

584


Are enumerations really portable?

594


What is structure data type in c?

569


Can you add pointers together? Why would you?

644


How can I remove the leading spaces from a string?

634