hey first to do it!!! #include struct employee { char name[20],mail[20]; int contact; float salary; }e[100];
void main() { int n,i; printf("\n\nenter the number of employees\n"); scanf("%d",&n); for(i=0;i<=n-1;i++) { printf("\nEnter contact no.\n "); scanf("%d",&e[i].contact); printf("\nenter the name of employee\n"); scanf("%s",e[i].name); printf("\nEnter salary of employee\n "); scanf("%f",&e[i].salary); printf("\nEnter mail id\n"); scanf("%s",e[i].mail);
void main() { int n,i; printf("\n\nenter the number of employees\n"); scanf("%d",&n); for(i=0;i<=n-1;i++) { printf("\nEnter contact no.\n "); scanf("%d",&e[i].contact); printf("\nenter the name of employee\n"); scanf("%s",e[i].name); printf("\nEnter salary of employee\n "); scanf("%f",&e[i].salary); printf("\nEnter mail id\n"); scanf("%s",e[i].mail);
#include void main() { struct emp { char name[20],mail[20]; float salary; int mno; }e[10]; int i; for(i=0;i<=9;i++) { printf("\nEnter the name of employee:"); scanf("%s",e[i].name); printf("\nEnter the Salary of employee:"); scanf("%f",&e[i].salary); printf("\nEnter the Contact no of employee:"); scanf("%d",&e[i].mno); printf("\nEnter the mail ID:\n"); scanf("%s",e[i].mail);
}
for(i=0;i<=9;i++) { printf("\nName of Employee=%s\nSalary of Employee=%f\nContact no of Employee=%d\nMail Id of Employee=%s",e[i].name,e[i].salary,e[i].mno,e[i].mail); } }
/*To display the name,contact no, email id & salary of employee by using array of structure */ #include void main() { struct emp { char name[20],mail[20]; float salary; int no; }e[10]; int i; for(i=0;i<=9;i++) { printf("\n\tEnter the name of employee:"); scanf("%s",e[i].name); printf("\n\tEnter the Salary of employee:"); scanf("%f",&e[i].salary); printf("\n\tEnter the Contact no of employee:"); scanf("%d",&e[i].no); printf("\n\tEnter the mail ID:"); scanf("%s",e[i].mail);
}
for(i=0;i<=9;i++) { printf("\n\tName of Employee=%s\n\tSalary of Employee=%f\n\tContact no of Employee=%d\n\tMail Id of Employee=%s",e[i].name,e[i].salary,e[i].no,e[i].mail); } }
//display info of employee #include void main() { int i; struct employee { char name[20],mail[20]; int no; float salary; }e[5];
for(i=0;i<=4;i++) { printf("\n\t enter the name of employee="); scanf("%s",e[i].name); printf("\n\t Enter the mail="); scanf("%s",e[i].mail ); printf("\n enter no="); scanf("%d",&e[i].no); printf("\nenter salary="); scanf("%f",&e[i].salary); }
#include void main() { struct emp { char name[50]; float salary; int id; int contactno; }e[10]; int i; for(i=0;i<=9;i++) { printf("\n\tEnter the name of employee\n\t"); scanf("%s",e[i].name); printf("\n\tEnter the salary of employee\n\t"); scanf("%f",&e[i].salary); printf("\n\tEnter the id of employee\n\t"); scanf("%d",&e[i].id); printf("\n\tEnter the contactno of employee"); scanf("%d",&e[i].contactno); } for(i=0;i<=9;i++) {
// Using array of structure display details of 10 employe #include void main() { int i; struct employe { char name[20]; float salary; char mailid[30]; int contact;
}e[10]; for(i=0;i<=9;i++) { printf("\n Enter name of employe="); scanf("%s",e[i].name); printf("\n Enter salary of employe="); scanf("%f",&e[i].salary); printf("\n Enter mail id of employe="); scanf("%s",e[i].mailid); printf("\n Contact no of employe="); scanf("%d",&e[i].contact); } for(i=0;i<=9;i++) { printf(" \n Name of empolyer =%s \t Salary of employer=%f \n Mail ID of employer=%s \t Contact number of employer=%d \n",e[i].name,e[i].salary,e[i].mailid,e[i].contact); } }
//information of employee using array #include void main()
{ struct emp { char name[20],mailID[20]; float salary; int mobno; }b[5]; int i;
for(i=0;i<=4;i++) { printf("\nenter the name of employee"); scanf("%s",b[i].name); printf("\nenter the mailID of employee"); scanf("%s",b[i].mailID); printf("\nenter the salary of employee"); scanf("%f",&b[i].salary); printf("\nenter the mobno of employee"); scanf("%d",&b[i].mobno); } for(i=0;i<=4;i++) { printf("\nname=%s,mailID=%s,salary=%f,mobno=%d",b[i].name,b[i].mailID,b[i].salary,b[i].mobno); } }
void main() { int i; struct employee { char name[10]; float salary; int number; char email[15]; }b[5]; for(i=1;i<=5;i++) { printf("\n Enter the name of the employee\n"); scanf("%s",b[i].name);
printf("\n Enter the salary of the employee::\n"); scanf("%f",&b[i].salary);
printf("\n Enter the mobile no of the employee::\n"); scanf("%d",&b[i].number);
printf("\n Enter the Email ID of the employee::\n"); scanf("%s",b[i].email);
} for(i=1;i<=5;i++) { printf("\n The name of the employee::%s \n The salary of employee::%f ",b[i].name,b[i].salary);
printf(" \n Mobile no of employee=%d \n\t Email ID ofemployee=%s" ,b[i].number,b[i].email ); } }
/*display n,s,c,id using array of struct*/ #include void main() { struct emp { char name[20]; float salary; int contactnum; int id; }e[5]; int i; for(i=0;i<=4;i++) { printf("\n\t enter name of emp"); scanf("%s",e[i].name); printf("\n\t enter salary of emp"); scanf("%f",&e[i].salary); printf("\n\t enter contactnum of emp"); scanf("%d",&e[i].contactnum); printf("\n\t enter id of emp"); scanf("%d",&e[i].id); } for(i=0;i<=4;i++) { printf("\n\tname=%s \n\tsalary=%f \n\tcontactnum=%d \n\tid=%d",e[i].name,e[i].salary,e[i].contactnum,e[i].id); } }
#include void main() { struct employee { char name[20]; float salary; int contnum; int idnum; }e[5]; int i; for(i=0;i<=4;i++) { printf("\nenter the name of employee"); scanf("%s",e[i].name); printf("\nenter the salary of employee"); scanf("%f",&e[i].salary); printf("\nenter the contnum of employee"); scanf("%d",&e[i].contnum); printf("\nenter the id of employee"); scanf("%d",&e[i].idnum); } for(i=0;i<=4;i++) { printf("\nemployee name =%s,salary=%f,contnum=%d,idnum=%d",e[i].name,e[i].salary,e[i].contnum,e[i].idnum); } }
#include void main() { struct emp { char name[20],mail[20]; float salary; int mno; }e[10]; int i; for(i=0;i<=9;i++) { printf("\nEnter the name of employee:"); scanf("%s",e[i].name); printf("\nEnter the Salary of employee:"); scanf("%f",&e[i].salary); printf("\nEnter the Contact no of employee:"); scanf("%d",&e[i].mno); printf("\nEnter the mail ID:\n"); scanf("%s",e[i].mail);
}
for(i=0;i<=9;i++) { printf("\nName of Employee=%s\nSalary of Employee=%f\nContact no of Employee=%d\nMail Id of Employee=%s",e[i].name,e[i].salary,e[i].mno,e[i].mail); } }
/*sructure of employee by array*/ #include void main() { int i; struct employee { char name[10]; int mno; int id; float salary; }e[5];
for(i=0;i<=4;i++) { printf("\n\t enter name"); scanf("%s",e[i].name); printf("\n\t enter mno"); scanf("%d",&e[i].mno); printf("\n\t enter id"); scanf("%d",&e[i].id); printf("\n\t enter salary"); scanf("%f",&e[i].salary); }
#include void main() { int i; struct Employee { int id; float sal; char name[10]; int cno; }e[10]; for(i=0;i<10;i++) { printf("Enter the name"); scanf("\n%s",e[i].name); printf("Enter the sal"); scanf("\n%f",&e[i].sal); printf("Enter the id"); scanf("\n%d",&e[i].id); printf("Enter the contact No"); scanf("\n%d",&e[i].cno); } for(i=0;i<10;i++) { printf("\nName of Employee=%s\nsalary of employee=%f\nId of Employee=%d\nContact No:%d\n",e[i].name,e[i].sal,e[i].id,e[i].cno); }
sample comment
ReplyDeletehey first to do it!!!
ReplyDelete#include
struct employee
{
char name[20],mail[20];
int contact;
float salary;
}e[100];
void main()
{
int n,i;
printf("\n\nenter the number of employees\n");
scanf("%d",&n);
for(i=0;i<=n-1;i++)
{
printf("\nEnter contact no.\n ");
scanf("%d",&e[i].contact);
printf("\nenter the name of employee\n");
scanf("%s",e[i].name);
printf("\nEnter salary of employee\n ");
scanf("%f",&e[i].salary);
printf("\nEnter mail id\n");
scanf("%s",e[i].mail);
}
printf("name\tcontact no\tsalary\tmail id\n");
printf("-------------------------------------------------\n");
for(i=0;i<=n-1;i++)
{
printf("\n%s\t%d\t%f\t%s\t",e[i].name,e[i].contact,e[i].salary,e[i].mail);
}
}
topper!!!!!
Deletetopper chi havach ahe rao
Delete#include
ReplyDeletestruct employee
{
char name[20],mail[20];
int contact;
float salary;
}e[100];
void main()
{
int n,i;
printf("\n\nenter the number of employees\n");
scanf("%d",&n);
for(i=0;i<=n-1;i++)
{
printf("\nEnter contact no.\n ");
scanf("%d",&e[i].contact);
printf("\nenter the name of employee\n");
scanf("%s",e[i].name);
printf("\nEnter salary of employee\n ");
scanf("%f",&e[i].salary);
printf("\nEnter mail id\n");
scanf("%s",e[i].mail);
}
printf("name\tcontact no\tsalary\tmail id\n");
printf("-------------------------------------------------\n");
for(i=0;i<=n-1;i++)
{
printf("\n%s\t%d\t%f\t%s\t",e[i].name,e[i].contact,e[i].salary,e[i].mail);
}
}
#include
ReplyDeletevoid main()
{
struct emp
{
char name[20],mail[20];
float salary;
int mno;
}e[10];
int i;
for(i=0;i<=9;i++)
{
printf("\nEnter the name of employee:");
scanf("%s",e[i].name);
printf("\nEnter the Salary of employee:");
scanf("%f",&e[i].salary);
printf("\nEnter the Contact no of employee:");
scanf("%d",&e[i].mno);
printf("\nEnter the mail ID:\n");
scanf("%s",e[i].mail);
}
for(i=0;i<=9;i++)
{
printf("\nName of Employee=%s\nSalary of Employee=%f\nContact no of Employee=%d\nMail Id of Employee=%s",e[i].name,e[i].salary,e[i].mno,e[i].mail);
}
}
#include
ReplyDeletevoid main()
{
struct emp
{
char name[10];
float salary;
int Contact no;
}e[10];
int i;
for(i=0;i<=9;i++)
{
printf("\nenter name of emp=");
scanf("%s",e[i].name);
printf("enter salary of emp=");
scanf("%f",&e[i].salary);
printf("enter id of emp=");
scanf("%d",&e[i].contact no);
}
for(i=0;i<=9;i++)
{
printf("\nemp name=%s,\nemp price=%f,\nemp pages=%d",e[i].name,e[i].salary,e[i].contact no);
}
}
#include
ReplyDeletevoid main()
{
struct Emp
{
char name[30];
char eid[30];
int mno;
float salary;
}e;
int i;
for(i=0;i<2;i++)
{
printf("\nEnter the name ,Mail_id,Mobile _no,salary\n");
scanf("%s%s%d%f",e.name,e.eid,&e.mno,&e.salary);
}
for(i=0;i<2;i++)
{
printf("\nInformation of Emp:\n");
printf("\nName=%s\nMail_id=%s\nMobile_no=%d\nSalary=%f\n",e.name,e.eid,e.mno,e.salary);
}
}
#include
Deletevoid main()
{
struct employee
{
char n[20],mail[20];
int sal,contact;
}e;
printf("\n\tEnter name,contact no,salary and mail id of employee:\n\t");
scanf("%s%d%d%s",e.n,&e.contact,&e.sal,e.mail);
printf("\n\tEmployee Details are:\n\t1.NAME=%s \n\t2.CONTACT NO.=%d \n\t3.SALARY=%d \n\t4.MAIL ID=%s",e.n,e.contact,e.sal,e.mail);
}
/*To display the name,contact no, email id & salary of employee by using array of structure */
ReplyDelete#include
void main()
{
struct emp
{
char name[20],mail[20];
float salary;
int no;
}e[10];
int i;
for(i=0;i<=9;i++)
{
printf("\n\tEnter the name of employee:");
scanf("%s",e[i].name);
printf("\n\tEnter the Salary of employee:");
scanf("%f",&e[i].salary);
printf("\n\tEnter the Contact no of employee:");
scanf("%d",&e[i].no);
printf("\n\tEnter the mail ID:");
scanf("%s",e[i].mail);
}
for(i=0;i<=9;i++)
{
printf("\n\tName of Employee=%s\n\tSalary of Employee=%f\n\tContact no of Employee=%d\n\tMail Id of Employee=%s",e[i].name,e[i].salary,e[i].no,e[i].mail);
}
}
//display info of employee
ReplyDelete#include
void main()
{
int i;
struct employee
{
char name[20],mail[20];
int no;
float salary;
}e[5];
for(i=0;i<=4;i++)
{
printf("\n\t enter the name of employee=");
scanf("%s",e[i].name);
printf("\n\t Enter the mail=");
scanf("%s",e[i].mail );
printf("\n enter no=");
scanf("%d",&e[i].no);
printf("\nenter salary=");
scanf("%f",&e[i].salary);
}
for(i=0;i<=4;i++)
{
printf("\nNAME=%s,\nMAIL ID=%s,\nNO=%d,\nSALARY=%f",e[i].name,e[i].mail ,e[i].no,e[i].salary);
}
}
#include
ReplyDeletevoid main()
{
struct emp
{
char name[50];
float salary;
int id;
int contactno;
}e[10];
int i;
for(i=0;i<=9;i++)
{
printf("\n\tEnter the name of employee\n\t");
scanf("%s",e[i].name);
printf("\n\tEnter the salary of employee\n\t");
scanf("%f",&e[i].salary);
printf("\n\tEnter the id of employee\n\t");
scanf("%d",&e[i].id);
printf("\n\tEnter the contactno of employee");
scanf("%d",&e[i].contactno);
}
for(i=0;i<=9;i++)
{
printf("\n\tEmployee Name=%s,Employee salary=%f,Employee id=%d,Contactno=%d",e[i].name,e[i].salary,e[i].id,e[i].contactno);
}
}
// Using array of structure display details of 10 employe
ReplyDelete#include
void main()
{
int i;
struct employe
{
char name[20];
float salary;
char mailid[30];
int contact;
}e[10];
for(i=0;i<=9;i++)
{
printf("\n Enter name of employe=");
scanf("%s",e[i].name);
printf("\n Enter salary of employe=");
scanf("%f",&e[i].salary);
printf("\n Enter mail id of employe=");
scanf("%s",e[i].mailid);
printf("\n Contact no of employe=");
scanf("%d",&e[i].contact);
}
for(i=0;i<=9;i++)
{
printf(" \n Name of empolyer =%s \t Salary of employer=%f \n Mail ID of employer=%s \t Contact number of employer=%d \n",e[i].name,e[i].salary,e[i].mailid,e[i].contact);
}
}
#include
ReplyDeletevoid main()
{
int i;
struct emp
{
char name[10];
char id[20];
int salary;
int cno;
int num;
}x[5];
for(i=0;i<=4;i++)
{
printf("\n enter employee name:");
scanf("%s",&x[i].name);
printf("\n enter salary:");
scanf("%d",&x[i].salary);
printf("\n enter the contact no:");
scanf("%d",&x[i].cno);
printf("\n enter the email id:");
scanf("%s",&x[i].id);
}
for(i=0;i<=4;i++)
{
printf("\n name=%s",x[i].name);
printf("\n salary=%d",x[i].salary);
printf("\n contact no=%d",x[i].cno);
printf("\n email id=%s",x[i].id);
}
}
//Employee strcture
ReplyDelete#include
void main()
{
struct employee
{
char name[10],mailid[10];
float salary;
int conatctno;
}e[5];
int i;
for(i=0;i<=4;i++)
{
printf("Enter name\n salary \nconatctno\nmailid");
scanf("\n%s\n%f\n%d\n%s",e[i].name,&e[i].salary,&e[i].conatctno,e[i].mailid);
printf("nane=%s\nsalary=%f\nconatctno=%d\nmailid=%s",e[i].name,e[i].salary,e[i].conatctno,e[i].mailid);
}
}
//information of employee using array
ReplyDelete#include
void main()
{
struct emp
{
char name[20],mailID[20];
float salary;
int mobno;
}b[5];
int i;
for(i=0;i<=4;i++)
{
printf("\nenter the name of employee");
scanf("%s",b[i].name);
printf("\nenter the mailID of employee");
scanf("%s",b[i].mailID);
printf("\nenter the salary of employee");
scanf("%f",&b[i].salary);
printf("\nenter the mobno of employee");
scanf("%d",&b[i].mobno);
}
for(i=0;i<=4;i++)
{
printf("\nname=%s,mailID=%s,salary=%f,mobno=%d",b[i].name,b[i].mailID,b[i].salary,b[i].mobno);
}
}
//program of displaying structure of employee
ReplyDelete#include
void main()
{
int i;
struct employee
{
char name[10];
float salary;
int number;
char email[15];
}b[5];
for(i=1;i<=5;i++)
{
printf("\n Enter the name of the employee\n");
scanf("%s",b[i].name);
printf("\n Enter the salary of the employee::\n");
scanf("%f",&b[i].salary);
printf("\n Enter the mobile no of the employee::\n");
scanf("%d",&b[i].number);
printf("\n Enter the Email ID of the employee::\n");
scanf("%s",b[i].email);
}
for(i=1;i<=5;i++)
{
printf("\n The name of the employee::%s \n The salary of employee::%f ",b[i].name,b[i].salary);
printf(" \n Mobile no of employee=%d \n\t Email ID ofemployee=%s" ,b[i].number,b[i].email );
}
}
#include
ReplyDeletevoid main()
{int i;
struct empolyee
{
char name[20],mail[20];
int salary,contact;
}p[5];
for(i=0;i<=4;i++)
{
printf("\nEmployee name=");
scanf("%s",p[i].name);
printf("\nsalary=");
scanf("%d",&p[i].salary);
printf("contact no=");
scanf("%d",&p[i].contact);
printf("\nenter mail ID=");
scanf("%s",p[i].mail);
}
for(i=0;i<=4;i++)
{
printf("name of Employee=%s\tsalary=%d\n\tcontact no=%d\n\tEmail ID=%s\n",p[i].name,p[i].salary,p[i].contact,p[i].mail);
}
}
/*display n,s,c,id using array of struct*/
ReplyDelete#include
void main()
{
struct emp
{
char name[20];
float salary;
int contactnum;
int id;
}e[5];
int i;
for(i=0;i<=4;i++)
{
printf("\n\t enter name of emp");
scanf("%s",e[i].name);
printf("\n\t enter salary of emp");
scanf("%f",&e[i].salary);
printf("\n\t enter contactnum of emp");
scanf("%d",&e[i].contactnum);
printf("\n\t enter id of emp");
scanf("%d",&e[i].id);
}
for(i=0;i<=4;i++)
{
printf("\n\tname=%s \n\tsalary=%f \n\tcontactnum=%d \n\tid=%d",e[i].name,e[i].salary,e[i].contactnum,e[i].id);
}
}
#include
ReplyDeletevoid main()
{
struct employee
{
char name[20];
float salary;
int contnum;
int idnum;
}e[5];
int i;
for(i=0;i<=4;i++)
{
printf("\nenter the name of employee");
scanf("%s",e[i].name);
printf("\nenter the salary of employee");
scanf("%f",&e[i].salary);
printf("\nenter the contnum of employee");
scanf("%d",&e[i].contnum);
printf("\nenter the id of employee");
scanf("%d",&e[i].idnum);
}
for(i=0;i<=4;i++)
{
printf("\nemployee name =%s,salary=%f,contnum=%d,idnum=%d",e[i].name,e[i].salary,e[i].contnum,e[i].idnum);
}
}
#include
ReplyDeletevoid main()
{
struct emp
{
char name[20],mail[20];
float salary;
int mno;
}e[10];
int i;
for(i=0;i<=9;i++)
{
printf("\nEnter the name of employee:");
scanf("%s",e[i].name);
printf("\nEnter the Salary of employee:");
scanf("%f",&e[i].salary);
printf("\nEnter the Contact no of employee:");
scanf("%d",&e[i].mno);
printf("\nEnter the mail ID:\n");
scanf("%s",e[i].mail);
}
for(i=0;i<=9;i++)
{
printf("\nName of Employee=%s\nSalary of Employee=%f\nContact no of Employee=%d\nMail Id of Employee=%s",e[i].name,e[i].salary,e[i].mno,e[i].mail);
}
}
/*sructure of employee by array*/
ReplyDelete#include
void main()
{
int i;
struct employee
{
char name[10];
int mno;
int id;
float salary;
}e[5];
for(i=0;i<=4;i++)
{
printf("\n\t enter name");
scanf("%s",e[i].name);
printf("\n\t enter mno");
scanf("%d",&e[i].mno);
printf("\n\t enter id");
scanf("%d",&e[i].id);
printf("\n\t enter salary");
scanf("%f",&e[i].salary);
}
for(i=0;i<=4;i++)
{
printf("name=%s,mno=%d,id=%d,salary=%f",e[i].name,e[i].mno,e[i].id,e[i].salary);
}
}
#include
ReplyDeletevoid main()
{
int i;
struct Employee
{
int id;
float sal;
char name[10];
int cno;
}e[10];
for(i=0;i<10;i++)
{
printf("Enter the name");
scanf("\n%s",e[i].name);
printf("Enter the sal");
scanf("\n%f",&e[i].sal);
printf("Enter the id");
scanf("\n%d",&e[i].id);
printf("Enter the contact No");
scanf("\n%d",&e[i].cno);
}
for(i=0;i<10;i++)
{
printf("\nName of Employee=%s\nsalary of employee=%f\nId of Employee=%d\nContact No:%d\n",e[i].name,e[i].sal,e[i].id,e[i].cno);
}
}
#include
ReplyDeletevoid main()
{
struct Emp
{
char name[30];
char eid[30];
int mno;
float salary;
}e;
int i;
for(i=0;i<2;i++)
{
printf("\nEnter the name ,Mail_id,Mobile _no,salary\n");
scanf("%s%s%d%f",e.name,e.eid,&e.mno,&e.salary);
}
for(i=0;i<2;i++)
{
printf("\nInformation of Emp:\n");
printf("\nName=%s\nMail_id=%s\nMobile_no=%d\nSalary=%f\n",e.name,e.eid,e.mno,e.salary);
}
}
#include
ReplyDeletevoid main()
{
struct emp
{
char name[20];
int salary;
int mbno;
char id[20];
}e[10];
int i;
for(i=0;i<9;i++)
{
printf("\n enter name");
scanf("%s",e[i].name);
printf("\n enter salary");
scanf("%d",&e[i].salary);
printf("\n enter mbno");
scanf("%d",&e[i].mbno);
printf("\n enter id");
scanf("%s",e[i].id);
}
for(i=0;i<9;i++)
{
printf("\n\t name=%s salary=%d mbno=%d id=%s",e[i].name,e[i].salary,e[i].mbno,e[i].id);
}
}
#include
ReplyDeletevoid main()
{
struct emp
{
char name[10];
int mob.no.;
int id;
float salary;
}e[5];
for(i=0;i<=4;i++)
{
printf("\nenter name");
scanf("%S",e[i].name);
printf("\n enter mob.no.");
scanf("%d",&e[i].mob.no.);
printf("\nenter id");
scanf("%d",&e[i].id);
printf("\nenter salary");
scanf("%f",&e[i].salary);
}
for(i=0;i<=4;i++)
{
printf("\nname=%s \nmob.no.=%d \n id=%d \n salary=%f",b[i].name,b[i].mob.no. ,b[i].id,b[i].salary);
}
}