1.

Represent the names of 12 months as an array of strings.ORA structure can contain another structure. Discuss.

Answer»

char month(1 2)[]={ “Jan”,”Feb”,”Mar”, “Apr”,May”,“Jun”,”July”,”Aug”, “Sep”,Oct”,“Nov”,”Dec”};

OR

Yes It is possible. This is called nested structure.

Eg.

struct date

{

short day,month,year

};

struct student

{

int reg_no;

char name[40];

date dob;

};



Discussion

No Comment Found