#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<malloc.h>
#define LEN sizeof(struct student)
#define MOD "学号 %-4d 姓名 %-8s VB 成绩 %4.2f C 成绩 %4.2f CPP 成绩 %4.2f 总分
%4.2f"
struct student
{int num;
char name[20];
float vb;
float c;
float cpp;
float sum;
struct student *next;
};
void menu(void);
struct student * rfile(void);
void wfile(struct student *head);
struct student *creat(void);
void schname(struct student *head);
struct student * schnum(struct student *head,int n);
void addata(struct student *head);
struct student * fskpoint(struct student *head,struct student *p);
void delet(struct student *head,int n);
void amend(struct student *head,int n);
void stusum(struct student *head);
void putdata(struct student *head);
void sort(struct student *head);
int n;//"n"为选择功能代号
#include"header_file.h"
void schname(struct student *head)
{
struct student *p;
char schname[20];
p=head;
printf(" 请输入姓名:");
评论2