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

正文內(nèi)容

數(shù)據(jù)結(jié)構(gòu)停車場管理課程設(shè)計報告(編輯修改稿)

2025-09-03 23:35 本頁面
 

【文章內(nèi)容簡介】 隊列的長度 Status GetHead(LinkQueue Q,QElemType amp。e) //若隊列不空,則用e返回Q的隊頭元素,并返回OK;否則返回ERROR Status EnQueue(LinkQueue amp。Q, QElemType e) //插入元素e為Q的新的隊尾元素 Status DeQueue(LinkQueue Q,QElemType amp。e) //若隊列不空,則刪除Q的隊頭元素,用e返回其值,并返回OK。 //否則返回ERROR Status QueueTraverse(LinkQueue Q,visit()) //從隊頭到隊尾依次對隊列Q中每個元素調(diào)用函數(shù)visit(),一旦visit失敗,則操作失敗。 其中部分操作的算法: void InitQueue(Shortcut amp。S){//初始化便道 ==(CarPtr)malloc(sizeof(Car2))。 next=NULL。 =0。}void EnQueue(Shortcut amp。S,int number,int ar_time){//車進(jìn)入便道 CarPtr p。 p=(CarPtr)malloc(sizeof(Car2))。 pnumber=number。 par_time=ar_time。 pnext=NULL。 next=p。 //相連 =p。 ++。}void DeQueue(Shortcut amp。S,CarPtr amp。w){//車離開便道 if(!=0) { w = next。 next=nextnext。 。 }}停車場、便道的類型 其中部分操作的算法:void Arrival(Park amp。P,Shortcut amp。S,int n){//對進(jìn)站車輛的處理 int number,ar_time。 printf(請輸入車牌號:)。 scanf(%d,amp。number)。 printf(進(jìn)場的時刻:)。 scanf(%d,amp。ar_time)。 if(n) { CarNode c。 =number。 =ar_time。 Push(P,c)。 printf(該車應(yīng)停在第%d號車道。\n,)。 } else { EnQueue(S,number,ar_time)。 printf(停車場已滿,請暫時停在便道的第%d個位置。\n,)。 }}void Leave(Park amp。P,Park amp。P1,Shortcut amp。S,int cost){//對離站車輛的處理 int number,le_time,flag,money。 CarPtr c,q。 int times。 printf(請輸入車牌號:)。 scanf(%d,amp。number)。 printf(出場的時刻:)。 scanf(%d,amp。le_time)。 CarNode e,m。 CarPtr w。 while() { Pop(P,e)。 if(==number) { flag=0。 money=()*cost。 times = 。 break。 } Push(P1,e)。 } while() { Pop(P1,e)。 Push(P,e)。 } // 車從停車場中出 if (flag == 0) { if(!=0) { DeQueue(S,w)。 =le_time。 =wnumber。 Push(P,m)。 free(w)。 printf(車牌號為%d的車已由便道進(jìn)入停車場\n,)。 } printf(停車費為%d, 停車時間為%d\n,money,times)。 } else { printf(停車場不存在牌號為%d的車,在便道上找\n, number)。 c = 。 if(!=0) { while(cnext!= NULL) { if(cnextnumber == number) { printf(%d車 從便道上離開,停留時間 %d\n,cnextnumber,le_time cnextar_time)。 cnext = cnextnext。
點擊復(fù)制文檔內(nèi)容
環(huán)評公示相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖片鄂ICP備17016276號-1