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 / 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 |
How do I determine whether a character is numeric, alphabetic, and so on?
How to get string length of given string in c?
A C E G H +B D F A I ------------ E F G H D
6)swap(int x,y) { int temp; temp=x; x=y; y=temp; } main() { int x=2;y=3; swap(x,y); } after calling swap ,what are yhe values x&y?
How pointers are declared?
write a program whose output will be- 1 12 123 1234
How can you tell whether two strings are the same?
How to write a code for random pick from 1-1000 numbers? The output should contain the 10 numbers from the range 1-1000 which should pick randomly, ie ,for each time we run the code we should get different outputs.
Who invented bcpl language?
Write the program that calculates and prints the average of several integers. Assume that the last value read is sentinel 9999.
There is a number and when the last digit is moved to its first position the resultant number will be 50% higher than the original number.Find the number?
Tell about strtok & strstr functions
2 Answers HCL, iFlex, Motorola,