那位高人能帮我做下C语言的题目,跪求

来源:百度知道 编辑:UC知道 时间:2024/05/10 08:18:05
目的:1。掌握一般磁盘文件的打开,关闭和读写操作
2。建立学生电子通讯录管理系统
要求:1。建立数据文件,内容包含5名学生的姓名及其电话和E—mail地址
2。查找用户输入的学生的电话或E-mail地址
3。插入用户输入新学生的姓名及电话和E-mail地址
4。删除用户输入的学生的姓名,电话和E-mail地址
5。用户可以在所提供的菜单中选择执行的操作
6。程序应具有一定的健壮性
试验训练原理
1。一般磁盘文件的输入和输出库函数的使用方法
2。一般磁盘文件的操作流程
实训项目1实训步骤
画出程序流程图
完成代码原型
上机编码实现程序
测试调试并运行,打印结果
完成实训报告,准备演示程序
介于流程图不方便,所以只要程序就行了
万分感谢
我也明白,我是学生,这个问题是在不会
我多等几天都没事
谢谢各位了

#include<stdio.h>
#include<alloc.h>
#define LEN sizeof(struct student)
struct student
{
char nam[20];
long phone;
char email[40];
struct student *next;
}*head=NULL;
void new()
{
struct student *head,*p;
insert();
}

insert()
{
struct student *p;
char c;
int i;
p=(struct student *)malloc(LEN);
printf("\nname:");
scanf("%s",&p->nam);
printf("\nphone:");
scanf("%ld",&p->phone);
printf("\nemail:");
scanf("%s",&p->email);
p->next=head;
head=p;
printf("\nDo you continue to insert Y or N\n");
fflush(stdin);
scanf("%c",&c);
if(c=='Y'||c=='y') insert();
if( c=='N'||c=='n') return ;
}
void display()
{<