Friday, April 19, 2019

Structure

0 comments

Structure

 Structure is a collection of heterogeneous type of data that it different type of data. So we can say that structure is a collection of different types of data type which consist different kinds of information. The various individual data component in structure can be accessed and process separately.
 A structure in a collection of variables referenced under one name providing convenient means of keeping related information together.
 The structure can be declared in C programming with the help of structure keyword.
 The general format of a structure depletion are follow:-
    syntax:-  structure 1 structure_name
                  {
                  data_type variable_name 1;
                  data_type variable_name 2;
                   _ _ _ _ _ _ _ _ _ _ _
                    };

  Ex.:-struct student
         { 
           int age;
           char name[20];
           float height;
           };
 

No comments:

Post a Comment