freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

c語言程序設(shè)計(醫(yī)院信息管理系統(tǒng))附源代碼-在線瀏覽

2024-09-17 04:17本頁面
  

【正文】 struct patient{ char id[10]。 char casehist[200]。 int transfusion。 struct patient *next。其中cost數(shù)組用來存儲病人賣藥的的個數(shù)(總共三種藥),casehist存儲病歷內(nèi)容,transfusion用來存儲病人輸液的花費,surgery存儲手術(shù)的花費。此外還要用到一個結(jié)構(gòu)體來存儲庫存中當前的藥品情況。 int price[3]。 函數(shù)定義、四個文件中所包含的函數(shù)說明如表所示。(2)初始化庫存令巴米爾、感冒靈、病毒唑3種藥的數(shù)量分別為10,價格分別為16。確認有可用鏈表之后進入modify函數(shù)。 printf(原有病歷: %s\n,tempcasehist)。 gets(a)。 gets(b)。 gets(c)。 strcat(tempcasehist,/)。 strcat(tempcasehist,/)。 strcat(tempcasehist,:)。 gets(d)。 2)載入鏈表信息是首先定義一個文件指針,然后以只讀方式打開文件。Flag值置為1,用來代表已有可用鏈表。 return head。 if(fread(rear,sizeof(struct patient),1,fp)) head=insert(head,rear)。 flag=1。 } }源程序代碼/**/ifndef FIRSTincludeincludeincludestruct patient{ //存儲一個病人的信息 char id[10]。 //name數(shù)組存儲病人姓名 char casehist[200]。 //cost數(shù)組存儲病人買藥的個數(shù)(總共三種) int transfusion。 //surgery存儲手術(shù)的花費 struct patient *next。struct storage{ //存儲庫存中當前的藥品情況 int amount[3]。}。void search(struct patient *temp)。 //列出所有病人的信息,參數(shù)為指向struct patient類型的指針struct patient *insert(struct patient *head,struct patient *rear)。 //修改病人病歷,參數(shù)為指向struct patient類型的指針void buy(struct patient *temp,struct storage *s)。 //將文件信息寫入到鏈表中,參數(shù)為指向struct patient類型的指針void save(struct patient *head)。 //定義字符數(shù)組 int sum。 gets(t)。amp。 } if(temp){ //temp的值為非0時,執(zhí)行下列步驟 printf(id: %s\n,tempid)。 printf(\n病歷: \n%s,tempcasehist)。 if(tempcost[0]){ printf(巴米爾 %d個\n,tempcost[0])。 } if(tempcost[2]){ printf(病毒唑 %d個\n,tempcost[2])。 } if(tempsurgery){ printf(手術(shù)費 %d\n,tempsurgery)。 //計算sum的值 printf(總費用 %d元,sum)。 }}void listall(struct patient *temp){ //定義listall函數(shù),列出所有病人的信息 printf(id 姓名\n)。 temp=tempnext。 if(head){ temp=head。 } tempnext=rear。 } else{ head=rear。 } return head。 //定義字符組 char a[4],b[2],c[2]。 gets(t)。amp。 } if(temp){ printf(原有病歷: %s\n,tempcasehist)。 gets(a)。 gets(b)。 gets(c)。 //把字符串a(chǎn)接到tempcasehist后面 strcat(tempcasehist,/)。 //把字符串b接到tempcasehist后面 strcat(tempcasehist,/)。 //把字符串c接到tempcasehist后面 strcat(tempcasehist,:)。 gets(d)。 //把字符串d接到tempcasehist后面 strcat(tempcasehist,\n)。 }}void buy(struct patient *temp,struct storage *s){ //病人消費處理 char t[10]。 int flag1。 gets(t)。amp。 } if(temp){ flag1=0。 scanf(%d,amp。 flag1=0。 flag1=1。 //flag1=1時,執(zhí)行循環(huán)體 flag1=0。 scanf(%d,amp。 flag1=0。 flag1=1。 //flag1=1時,執(zhí)行循環(huán)體 flag1=0。 scanf(%d,amp。 flag1=0。 flag1=1。 //flag1=1時,執(zhí)行循環(huán)體 tempcost[0]+=a。 //temp
點擊復(fù)制文檔內(nèi)容
環(huán)評公示相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1