+ 1
What is a struct or a union?
3 Respuestas
+ 3
one major difference of structure and union is that the structure has a separate memory location for each of its members whereas, the members of a union share the same memory location. In union, the total memory space allocated is equal to the member with largest size. All other members share the same memory space. This is the biggest difference between structure and union from what i recall
+ 2
data structure is a group of data elements grouped together under one name. These data elements, known as members, can have different types and different lengths. so lets say students the share common data right.. structure has three members: name (string), number (integer) and marks in exam (float) we could design a structure to suit. many things show structure i will let others explain union pointers etc lol
+ 1
I don't know what they are... It's also difficult to understand how pointers and memory works...