9. Which is the right answer to the following: struct S { int i; float f; }; union u { int i; float f; }; Which of the following expressions is true? Pick ONE option
Answers
Answered by
1
Answer:
the answer is union u is the correct answer
Answered by
0
Answer
sizeof(struct S)>sizeof(union u)
Step-by-step explanation:
- Struct is the keyword for structures and is used to combine a number of connected variables under one place
- Union comes under a type of structure and is used when memory turns to be a deciding factor
- (sizeof) operator gives the memory size of its operand
- Members under structure occupies separate memory location
- Members under union occupies the same memory loaction
Similar questions
Math,
3 hours ago
English,
3 hours ago
Science,
3 hours ago
CBSE BOARD X,
6 hours ago
Math,
8 months ago