【正文】
最后:每一款編程的語(yǔ)言都有各自的優(yōu)缺點(diǎn)。這些都使我獲益匪淺,另外必須說(shuō)的是在整個(gè)上機(jī)實(shí)習(xí)過(guò)程中老師們都表現(xiàn)的很負(fù)責(zé),很有耐心的幫助我們解決問(wèn)題。通過(guò)大家的通力合作以及老師的細(xì)心講解。 下面事各個(gè)模塊的界面圖:(1) 主菜單函數(shù)效果如圖所(2) 錄入信息模塊效果如圖所示 (3) 統(tǒng)計(jì)模塊 效果如圖所示(4) 查詢模塊效果如圖所示 (5) 修改模塊效果如圖所示總結(jié)此次實(shí)習(xí)中,我成功做出了課堂上老師要求的內(nèi)容。if(w1==1)save(n)。printf_one(i)。break。do{switch(c){case 1:no_input(i,n)。c)。modify_data(int i,int n){int c,w1。w)。void browse()。 fclose(fp)。room[i].client_list[j].age,room[i].client_list[j].ID_card,amp。room[i].room_ID,room[i].tel,amp。!feof(fp)。int i,j。return 1。i++) for(j=0。if((fp=fopen(,w))==NULL){printf(\nCannot open file\n)。break。puts(1).modify again\t2).back\n)。else printf(NO record this day\n)。(room[i].client_list[j].month==b)amp。i++) for(j=0。c)。scanf(%d,amp。puts(\nYear:)。break。 case 10:printf(Please input the new price\n)。 case 9:printf(Please input the new tel\n)。scanf(%d,amp。a)。room[i].client_list[j].month=a。break。 case 5:printf(Please input new year\n)。 case 4:printf(Please input new ID_card\n)。scanf(%d,amp。a)。strcpy(room[i].client_list[j].name,s)。scanf(%d,amp。char s[20],b[15]。 switch(l) {case 1:modify_one()。puts(What you want to do?\n)。 if(w==1) printf_p(m,n)。ir。puts(\t\tPlease input the name)。break。}while(m==1)。amp。printf(\t\tPlease choice your number(13):[ ]\b\b)。puts(\t\t\t\t1).modify one people\n)。 case 2:search()。scanf(%d,amp。(room[i].client_list[j].year==a)) w=1,m=i,n=j,printf_p(m,n)。j++) if((room[i].client_list[j].date==c)amp。for(i=0。printf(\nDate:)。a)。 }}void search_day() /*******查詢某日的使用情況*******/{int i,j,l,m,n,a,b,c,w=0。l)。else printf(\nThere is no record here\n)。i++) for(j=0。scanf(%s,s)。 case 3:menu()。 switch(n){case 1:search_one()。n3) {m=1。scanf(%d,amp。puts(\t\t2).Search someday \n)。printf(\nPrice:%d\n,room[i].price)。printf(\nmonth:%d\n,room[i].client_list[j].month)。printf(\nage:%d\n,room[i].client_list[j].age)。 case 2:stat()。scanf(%d,amp。j++) { if(room[j].sign==1) s+=1。 }}void stat_u() /******統(tǒng)計(jì)使用中的房間*****/{int j,l,s=0。l)。printf(There are %d customer this month,s)。ir。scanf(%d,amp。 case 3:menu()。 switch(n){case 1:stat_o()。n3) {m=1。scanf(%d,amp。puts(\t\t\t\t2).Statistics using room\n)。}(2)統(tǒng)計(jì)模塊[需求分析] 該模塊的功能是顯示所有客戶記錄信息。 } } r=r+m。room[i].client_list[j].month)。scanf(%d,amp。room[i].client_list[j].age)。scanf(%d,amp。jp+n。scanf(%d,amp。room[i].room_ID)。for(i=r。n)。各功能模塊函數(shù)部分:(1)輸入模塊[需求分析] 對(duì)信息進(jìn)行輸入。void stat_u()。void modify_day()。void search_day()。int r=0。 int price。 int date。 int age。case 5:exit(0)。case 3:search()。switch(n){case 1:regist()。n)。puts(\t\t\t ||(5).Exit ||\n)。puts(\t\t\t ||(1).Regist ||\n)。 save()。scanf(%d,amp。 puts(\n\tMonth:\t)。scanf(%s,room[i].client_list[j].ID_card)。 puts(\n\tAge:\t)。scanf(%s,room[i].client_list[j].name)。 room[i].sign=1。scanf(%s,room[i].tel)。