Q8. How is structure different from an array?
Ans. An array can hold multiple elements of same data type whereas a structure can hold multiple elements of different data types.
The component element of an array is referenced by the array name and the index value, for example, NAME, FILE etc. On the other hand, the component element of a structure is referenced by the structure name and the element name for example, style.main, check.value etc.