};
int main()
{
student student1[2];
for(int i=0; i<2; i++)
{
cout<<"please enter the first name of student "<<i+1<<endl;
cin.getline(student1[i].firstName,20,'\n');
cout<<"please enter the last name of student "<<i+1<<endl;
cin.getline(student1[i].lastName,20,'\n');
cout<<"please enter the roll number of student "<<i+1<<endl;
cin.getline(student1[i].rollNo,20,'\n');
cout<<"please enter the quiz 1 marks of student "<<i+1<<endl;
cin>>student1[i].quiz1;
cout<<"please enter the quiz 2 marks of student "<<i+1<<endl;
cin>>student1[i].quiz2;
}
for(int j=0; j<2; j++)
{
cout<<"First Name of student "<<j+1<<": "<<student1[j].firstName<<endl;
cout<<"Last Name of student "<<j+1<<": "<<student1[j].lastName<<endl;
cout<<"Roll number of student "<<j+1<<": "<<student1[j].rollNo<<endl;
cout<<"Quiz 1 marks of student "<<j+1<<": "<<student1[j].quiz1<<endl;
cout<<"Quiz 2 marks of student "<<j+1<<": "<<student1[j].quiz2<<endl;
}
int main()
{
student student1[2];
for(int i=0; i<2; i++)
{
cout<<"please enter the first name of student "<<i+1<<endl;
cin.getline(student1[i].firstName,20, '\n');
cout<<"please enter the last name of student "<<i+1<<endl;
cin.getline(student1[i].lastName,20,'\n');
cout<<"please enter the roll number of student "<<i+1<<endl;
cin.getline(student1[i].rollNo,20,'\n');
cout<<"please enter the quiz 1 marks of student "<<i+1<<endl;
cin>>student1[i].quiz1;
cout<<"please enter the quiz 2 marks of student "<<i+1<<endl;
cin>>student1[i].quiz2;
cin.ignore();
}
for(int j=0; j<2; j++)
{
cout<<"First Name of student "<<j+1<<": "<<student1[j].firstName<<endl;
cout<<"Last Name of student "<<j+1<<": "<<student1[j].lastName<<endl;
cout<<"Roll number of student "<<j+1<<": "<<student1[j].rollNo<<endl;
cout<<"Quiz 1 marks of student "<<j+1<<": "<<student1[j].quiz1<<endl;
cout<<"Quiz 2 marks of student "<<j+1<<": "<<student1[j].quiz2<<endl;
}
return 0;
}