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

正文內(nèi)容

商品信息管理系統(tǒng)c語(yǔ)言課程設(shè)計(jì)(參考版)

2024-08-30 15:49本頁(yè)面
  

【正文】 p1number=c。 if(p2numberp1number) { c=p2number。j++) { p2=p1。i++) { for(j=i+1。 for(i=1。 printf(商品編號(hào) \t 商品名稱 \t 商品類別 \t 庫(kù)存數(shù)量 \t 商品價(jià)格\n)。/*選擇操作 */ } switch(a)/*用 switch 詫句實(shí)現(xiàn)功能選擇 */ { /*============================================================*/ case 1: /*按商品編號(hào)順序?yàn)g覽 */ { system(cls)。 scanf(%d,amp。 printf(\n\n\n\n\n\n\n)。 printf(\t\t\t\t\t\t\t $$)。 printf(\t \t\t\t\t\t\t $$\n)。 printf(\t $$\t\t\t\t\t\t $$\n)。 printf(\t $$\n)。 printf(\t $$\n)。 } lp2: { printf(\n\n\n\n\n\n)。 system(cls)。/*清屏 */ if(head==NULL) { printf(\n\n\n 沒(méi)有仸何商品資料,請(qǐng)先建立商品資料 !\n)。 char t[100]。 long c。 } print 函數(shù) void print(information *head)/*函數(shù) print,功能:顯示商品信息 */ { information *p1,*p2。 system(cls)。 goto lp4。 } else { printf(丌存在 %d 號(hào)商品 !\n,num)。 printf(%ld\t\t%s\t\t%s\t\t%d\t\t%.2f\n,p1number,p1name,p1leibie,p1kucun,p 1jiage)。 printf(\n 該商品現(xiàn)在的信息是: )。 goto lp5。t)。 lp5:printf(\n 請(qǐng)輸入該商品的售貨量: )。 printf(\n 商品編號(hào) \t 商品名 稱 \t 商品類別 \t 庫(kù)存數(shù)量 \t 商品價(jià)格 \n)。 p1=p1next。amp。 } while(num!=0) { p1=head。 } else while(num1000000||num=10000000) { printf(輸入錯(cuò)諢,請(qǐng)重新輸入商品編號(hào) :)。 if(num==0) { system(cls)。 lp4:scanf(%ld,amp。 return(head)。 getch()。 system(cls)。 long num。 } sales 函數(shù) information *sales(information *head) /*定義輸入銷售信息的函數(shù)。 system(cls)。 goto lp3。 } else { printf(丌存在 %d 號(hào)商品 !\n,num)。 printf(%ld\t\t%s\t\t%s\t\t%d\t\t%.2f\n,p1number,p1name,p1leibie,p1kucun,p 1jiage)。 printf(\n 該商品現(xiàn)在的信息是: )。t)。 printf(\n 請(qǐng)輸入該商品的迚貨量: )。 printf(\n 商品編號(hào) \t 商品名稱\t 商品類別 \t 庫(kù)存數(shù)量 \t 商品價(jià)格 \n)。 p1=p1next。amp。 } while(num!=0) { p1=head。 } while(num1000000||num=10000000) 27 { printf(輸入錯(cuò)諢,請(qǐng)重新輸入商品編號(hào) :)。 if(num==0) { system(cls)。 lp3:scanf(%ld,amp。 return(head)。 getch()。 system(cls)。 long num。 } purchase 函數(shù) information *purchase(information *head)/*定義輸入迚貨信息的函數(shù)。 system(cls)。 } printf(\n 現(xiàn)在的商品數(shù)為 :%d 個(gè) !\n,n)。 } else { printf(沒(méi)有找到 %l 這件商品 !,num)。 n=n1。 /*若 p1 指向的是首結(jié)點(diǎn),把地 二個(gè)結(jié)點(diǎn)地址賦予 head*/ 26 else p2next=p1next。a)。 printf(是請(qǐng)按( 1),否請(qǐng)按( 0) !\n)。 printf(%ld\t\t%s\t\t%s\t\t%d\t\t%.2f\n,p1number,p1name,p1leibie,p1kucun,p 1jiage)。 p1=p1next。amp。 } p1=head。 scanf(%d,amp。 return (head)。num)。 } lp:printf(請(qǐng)輸入你需要?jiǎng)h除的商品的編號(hào)( 7 位) (按 0 退出 ):)。 system(cls)。/*清屏 */ if(head==NULL) { printf(\n\n\n 沒(méi)有仸何商品資料,請(qǐng)先建立商品資料 !\n)。 long num。 } del 函數(shù) information *del(information *head)/*函數(shù) del,功能:刪除商品信息 */ { 25 information *p1,*p2。 goto pp。 } } else printf(%d 丌存在此商品 !\n,num)。 } else { system(cls)。 return(head)。t)。 printf(確認(rèn)請(qǐng)按( 1) !重新請(qǐng)按( 2) !\n)。 printf(\n 商品編號(hào) \t 商品名稱\t 商品類別 \t 迚貨數(shù)量 \t 商品價(jià)格 \n)。p1jiage)。 while(p1jiage0) { printf(輸入錯(cuò)諢,請(qǐng)重新輸入商品價(jià)格 )。 scanf(%f,amp。p1kucun)。 while(p1kucun0) 24 { printf(輸入錯(cuò)諢,請(qǐng)重新輸入商品數(shù)量 )。 scanf(%d,amp。p1leibie)。 printf(請(qǐng)輸入修改后的商品類別: )。 scanf(%s,amp。p1number)。 while(p1number1000000||p1number=10000000) { printf(輸入錯(cuò)諢,請(qǐng)重新輸入 7 位商品編號(hào) :)。 scanf(%ld,amp。t)。 printf(修改請(qǐng)按( 1) !退出請(qǐng)按( 0) !)。 } if(num==p1number) { printf(\n 商品編號(hào) \t 商品名稱 \t 商品類別 \t 庫(kù)存數(shù)量 \t 商品價(jià)格 \n)。p1next!=NULL) { p2=p1。 while(num!=p1numberamp。num)。 } else while(num1000000||num=10000000) { printf(輸入錯(cuò)諢,請(qǐng)重新輸入商品編號(hào) :)。 if(num==0) { system(cls)。 pp:scanf(%ld,amp。 return(head)。 getch()。 system(cls)。 long num。 } amend 函數(shù) information *amend(information *head)/*定義一個(gè)修改商品信息信息的函數(shù)。 end2: system(cls)。 } else goto repeat。 } } n=n+1。 } p0next=p2。/*將它不新開(kāi)單元相連接 */ } else { while(p0next!=NULL)/*還沒(méi)找到末尾,繼續(xù)找 */ { p2=p0。 22 }/*當(dāng)原來(lái)鏈表為空時(shí),從首結(jié)點(diǎn)開(kāi)始存放資料 */ else/*原來(lái)鏈表丌為空 */ { if(p0next==NULL)/*找到原來(lái)鏈表的末尾 */ { p0next=p2。 if(head==NULL) { head=p2。 if(a==1) { p0=head。 scanf(%d,amp。 printf(你確定要新增這個(gè)商品嗎 ?\n)。 } printf(\n 商品編號(hào) \t 商品名稱 \t 商品類別 \t 庫(kù)存數(shù)量 \t 商品價(jià)格 \n)。 scanf(%f,amp。newgoodsjiage)。 } printf(請(qǐng)輸入商品價(jià)格(大于 0): )。/*輸入錯(cuò)諢,重新輸入商品庫(kù)存直到正確為止 */ scanf(%d,amp。newgoodskucun)。 printf(請(qǐng)輸入商品庫(kù)存(大于 0): )。 scanf(%s,amp。newgoodsname)。 } } } } printf(請(qǐng)輸入商品名: )。 else { printf(編號(hào)重復(fù) ,請(qǐng)重輸 !\n)。in。 } p1=head。 scanf(%d,amp。 if(newgoodsnumber==0) goto end2。 scanf(%ld,amp。/*開(kāi)辟一個(gè)新單元 */ system(cls)。 int i,a。 } goto lp2。 return(head)。 break。 system(cls)。 printf(\n 需要迚貨的商品有以上 %d 種 !,b)。 20 } p1=p1next。 if(head!=NULL) do { if(p1kucun50) { printf(%ld\t\t%s\t\t%s\t\t%d\t\t%.2f\n,p1number,p1name,p1leibie,p1kucun,p 1jiage)。 printf(商品編號(hào) \t 商品名稱 \t 商品類別 \t 庫(kù)存數(shù)量 \t 商品價(jià)格 \n)。 /*============================================================*/ case 4: { system(cls)。 } goto lp8。 if(b==0) { printf(\n 丌存在 %s 該類型商品 !\n,t)。 } p1=p1next。 do { if(strcmp(t,p1leibie)==0) { printf(%s\t\t%ld\t\t%s\t\t%d\t\t%.2f\n,p1leibie,p1number,p1name,p1kucun,p 1jiage)。 p1=head。 b=0。 scanf(%s,amp。 /*======
點(diǎn)擊復(fù)制文檔內(nèi)容
法律信息相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1