#include <stdio.h>
#include <malloc.h>
#define LEN sizeof(struct student)
struct student
{
int num;
char name[8];
char sex;
int age;
struct student * next;
};
int main()
{
struct student * creat();
struct student * del(struct student *,int );
void print(struct student * );
struct student * head,* p;
int age;
printf("请输入英雄信息:\n");
head=creat();
printf("请输入要删除的英雄年龄:");
scanf("%d",&age);
head=del(head,age);
printf("年龄为%d的英雄已删除,剩下的英雄:\n",age);
print(head);
return 0;
}
struct student * creat()
{
struct student * head, * p1,* p2;
int n=0;
p1=p2=(struct student *)malloc(LEN);
scanf