What's the difference between struct x1 { ... }; and
typedef struct { ... } x2; ?
Answer Posted / vikraman85
In the first its simply structure,by declaring structure
variable accessors we can access those elements inside the
structure..
eg.struct x1 a,b,c;
In the next one the x2 acts as a datatype..
b'coz of the typedef function..
we can use x2 as datatype for the further calculations like
int,float which are predefined datatypes,but this is
manually defined datatype..
Is This Answer Correct ? | 16 Yes | 3 No |
Post New Answer View All Answers
Explain high-order and low-order bytes.
What is a lvalue
Write a code of a general series where the next element is the sum of last k terms.
Is flag a keyword in c?
What is the difference between if else and switchstatement
What is the size of enum in c?
Write a factorial program using C.
any limit on the number of functions that might be present in a C program a) max 35 functions b) max 50 functions c) no limit d) none of the above
How can I make it pause before closing the program output window?
what are the advantages of a macro over a function?
c program for searching a student details among 10 student details
What is meant by realloc()?
How can I get the current date or time of day in a c program?
Why clrscr is used in c?
What does %p mean?