# include
# include
Struct student/* define student achievement structure */
{
int num;/* */student id
Char name [15]./* name */
Double elec./* optional */
Double expe./* */experimental
Double requ; Compulsory/* */
Double sum;/* */total score
};
Struct student stu [50]./* * defined structure array/
Void in () {}/* enter */student achievement information
Void the show () {}/* information display students */
Void the order () {}/* total score by the */
Void del () {}/* */delete student achievement information
Void the modify () {}/* */modify student achievement information
Void the insert () {}/* insert student information */
Void total () {}/* */
the total number of calculationVoid the search () {}/* to find students information */
Void main ()/* */
main function{void menu ();
int n;
The menu ();
The scanf (" % d ", & amp; N); The number of *//* input selection function
While (n)
{
The switch (n)
{
Case 1:
In ();
break;
Case 2:
Search ().
break;
Case 3:
Del ();
break;
Case 4:
The modify ();
break;
Case 5:
Insert ();
break;
Case 6:
The order ();
break;
Case 7:
Total ();
break;
Default: break;
}
getch();
The menu ();/* performed again display menu interface */
The scanf (" % d ", & amp; N);
}
}
Void menu ()/* */custom function menu function
{
system("cls");
Printf (" \ n \ n \ n \ n \ n ");
Printf (" \ t \ t | -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - STUDENT -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - | \ n ");
Printf (" \ t \ t | 1. Input student achievement | \ n ");
Printf (" \ t \ t | 2. Query student achievement | \ n ");
Printf (" \ t \ t | 3. Delete student achievement | \ n ");
Printf (" \ t \ t | 4. Modify the student achievement | \ n ");
Printf (" \ t \ t | 5. Insert the student achievement | \ n ");
Printf (" \ t \ t | 6. Student achievement sorting | \ n ");
Printf (" \ t \ t | 7. Statistics the number of students | \ n ");
Printf (" \ t \ t | 0. Exit system | \ n ");
Printf (" \ t \ t | -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - | \ n \ n ");
Printf (" \ t \ t option (0 to 7) : ");
}