union
{
char ch[10];
short s;
}test;
test.s = 0xabcd;
main()
{
printf("%d",ch[10]);
}
Answer Posted / shrikant auti
The code written is incorrect......
union
{
char ch[10];
short s;
}test;
test.s = 0xabcd;
main()
{
printf("%d",ch[10]);/*%D CAN'T BE USED FOR CHARACTER
EXTRACTION*/
}
| Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
What do header files do?
Where static variables are stored in memory in c?
What is structure padding in c?
Can the sizeof operator be used to tell the size of an array passed to a function?
What is this pointer in c plus plus?
Explain main function in c?
Function calling procedures? and their differences? Why should one go for Call by Reference?
What does %p mean?
Where is c used?
Explain about the functions strcat() and strcmp()?
Explain low-order bytes.
When should a type cast be used?
What is dynamic dispatch in c++?
How many parameters should a function have?
What is mean by Data Driven framework in QTP? Can any one answer me in details on this regard.