Which of the Following will define a type NODE that is a
node in a Linked list?
A)struct node {NODE*next;int x;};type def struct node NODE;
B)typedef struct NODE {struct NODE *next;int x;};
C)typedef struct NODE {NODE *next;int x;};
D)typedef struct {NODE *next;int x;}NODE;

Answer Posted / shahzad

B)
coz ..linked list node contain two parts ..
one is address to next node
other is data part in single list....
writting keyword struct before NODE is must..

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When is a “switch” statement preferable over an “if” statement?

640


What is the code for 3 questions and answer check in VisualBasic.Net?

1682


What is the difference between array_name and &array_name?

774


Write a program with dynamically allocation of variable.

600


Not all reserved words are written in lowercase. TRUE or FALSE?

719






Explain logical errors? Compare with syntax errors.

618


What is a global variable in c?

587


What is data structure in c programming?

567


Explain the use of 'auto' keyword in c programming?

677


Is it better to use a macro or a function?

649


What are operators in c?

575


All technical questions

1505


How can I use a preprocessorif expression to ?

595


write a program to concatenation the string using switch case?

1552


List the difference between a 'copy constructor' and a 'assignment operator' in C?

637