0
872views
How to create a array of structure variables and assign to its members?

Subject : Structured Programming Approach

Title : Arrays, String, Structures and Union

Difficulty : Medium

1 Answer
0
38views
  1. An array of structure can be declared in the same way as declaring array of any other data type.

  2. For example, an array of the structure student can be declared as shown:struct student s[100];This array can now store information of 100 students.

  3. Array of structure must be used when many variables of a structure are required.

  4. Syntax:

    Struct structure_name

    {data_type member1;

    data_type member2;

    -

    -

    data_type member;

    };

Please log in to add an answer.