Problem Solving Through C (BCA) 1st Sem Previous Year Solved Question Paper 2022

Practice Mode:
21.

How are structures different from arrays ?

Explanation

Structures and arrays differ in the following ways:

  1. Data Organization:

    • Arrays store elements of the same data type in a contiguous memory block.

    • Structures can store elements of different data types in a single unit but not necessarily in contiguous memory.

  2. Access:

    • Array elements are accessed using indices.

    • Structure members are accessed using member names.