Find the O/p of the following

struct node
{
char *name;
int num;
};
int main()
{
struct node s1={"Harry",1331};
struct node s2=s1;
if(s1==s2)
printf("Same");
else
printf("Diff");
}

Answer Posted / sinchan garai

this gives a compile time error.because the coditional
statement "if(s1==s2)" written in the code is not allowable
in C.

Is This Answer Correct ?    4 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When the macros gets expanded?

1123


Explain built-in function?

876


What are the data types present in c?

866


How can a program be made to print the line number where an error occurs?

895


What is #include cctype?

850


Why header file is used in c?

803


What is "Hungarian Notation"?

858


What is structure and union in c?

848


how logic is used

1735


Explain how do you list a file’s date and time?

826


What is far pointer in c?

1028


How to write a code for implementing my own printf() and scanf().... Please hep me in this... I need a guidance... Can you give an coding for c... Please also explain about the header files used other than #include...

5188


What's the difference between constant char *p and char * constant p?

920


typedef enum { html, java, javascript, perl, cgi } lang;The above statement defines a : a) Union b) User defined type c) Enumerated variable d) none

991


What is extern c used for?

795