In this program we are going to implement a structure Personal which contains name, date of joining and salary of employees.
To learn about structure and union from beginning Click Here.
//Declaration of structure Personal
//Structure data members declaration
//Using an array to hold information of 5 employees
//Values are being inserted by user
printf("\nEnter the following information of employees:");
printf("\nJoining date(date and month as 2203):");
//Printing Employee information on output window
printf("\nEntered information is as follows:");
printf("\n|| S.No. || Name || Salary || Joining Date |");
printf("\n|| %d || %s %d %d ",i+1,per[i].name,per[i].salary,per[i].date);
For More GTU C Programming Lab Experiments Click Here