图遍历的演示实习报告c++

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

eaintheaccidentinvestigation,managementandreporting,eachpostshouldbedevelopedunderthissystemspecialistscheck,cleartheexaminations,time,cyclesandotherrelevantregulations.Strengtheningsitesupervisionandexamination,todetectandinvestigateillegalcommand,illegaloperationsandviolationsofoperatingrules.Secondsafetyreferstotheproductionsite,technologymanagement,equipment,facilities,andsooncanleadtoaccidentsrisksexist.1,accordingtotheextentofthesecurityrisks,solvingisdividedintoa,b,andclevelsofdifficulty;A-level:difficult,miningdifficulties,shallbereportedtothecompany'sproblems.B-class:difficulttoresolvedif听范读短文的录音。学生根据拼音自由朗读短文,不会拼读的音节求助同学或老师。听老师读短文,把自己不会认读的字和词听清楚。指名朗读,重点纠正“蓝”“绿”“帆”的读音。齐读短文,进一步熟悉短文。你最喜欢哪一句话?指导学生有感情地朗读。ficulties,shallconsistofminingorganizationstosolveproblems.C-class:fromsegmentsandbusinessrisksthatmustbeaddressedintheDepartment.2,open-pitmineunsafetypesinclude:electrical,transport,blasting,fire,andotherslope.3,accordingtotheseverityofthehazardfilledinbyunittroubleshooting,registrationform(seeatt数据结构课程设计图遍历的演示eaintheaccidentinvestigation,managementandreporting,eachpostshouldbedevelopedunderthissystemspecialistscheck,cleartheexaminations,time,cyclesandotherrelevantregulations.Strengtheningsitesupervisionandexamination,todetectandinvestigateillegalcommand,illegaloperationsandviolationsofoperatingrules.Secondsafetyreferstotheproductionsite,technologymanagement,equipment,facilities,andsooncanleadtoaccidentsrisksexist.1,accordingtotheextentofthesecurityrisks,solvingisdividedintoa,b,andclevelsofdifficulty;A-level:difficult,miningdifficulties,shallbereportedtothecompany'sproblems.B-class:difficulttoresolvedif数据结构课程设计图的遍历胡海洪听范读短文的录音。学生根据拼音自由朗读短文,不会拼读的音节求助同学或老师。听老师读短文,把自己不会认读的字和词听清楚。指名朗读,重点纠正“蓝”“绿”“帆”的读音。齐读短文,进一步熟悉短文。你最喜欢哪一句话?指导学生有感情地朗读。ficulties,shallconsistofminingorganizationstosolveproblems.C-class:fromsegmentsandbusinessrisksthatmustbeaddressedintheDepartment.2,open-pitmineunsafetypesinclude:electrical,transport,blasting,fire,andotherslope.3,accordingtotheseverityofthehazardfilledinbyunittroubleshooting,registrationform(seeatt1题5.3图遍历的演示实习报告题目:试设计一个程序,演示在连通和非连通的无向图上访问全部结点的操作一、需求分析1、以邻接多重表为存储结构;2、实现连通和非连通的无向图的深度优先和广度优先遍历;3、要求利用栈实现无向图的深度优先遍历;4、以用户指定的结点为起点,分别输出每种遍历下的结点访问序列和生成树的边集;5、用凹入表打印生成树;6、求出从一个结点到另外一个结点,但不经过另外一个指定结点的所有简单路径;6、本程序用C++语言编写,在TURBOC++3.0环境下通过。二、概要设计1、设定图的抽象数据类型:ADTGraph{数据对象V:V是具有相同特性的数据元素的集合,称为点集.数据关系R:R={VR}VR={(v,w)|v,w属于V,(v,w)表示v和w之间存在的路径}基本操作P:CreatGraph(&G,V,VR)初始条件:V是图的顶点集,VR是图中弧的集合.操作结果:按V和VR是定义构造图G.DestroyGraph(&G)初始条件:图G存在操作结果:销毁图GLocateVex(G,u)初始条件:图G存在,u和G中顶点有相同的特征操作结果:若图G中存在顶点u,则返回该顶点在图中的位置;否则返回其他信息GetVex(G,v)初始条件:图G存在,v是G中顶点操作结果:返回v的值FirstAjvex(G,v)初始条件:图G存在,v是G中顶点操作结果:返回v的第一个邻接顶点,若顶在图中没有邻接顶点,则返回为空NextAjvex(G,v,w)初始条件:图G存在,v是G中顶点,w是v的邻接顶点操作结果:返回v的下一个邻接顶点,若w是v的最后一个邻接顶点,则返回空DeleteVexx(&G,v)初始条件:图G存在,v是G中顶点操作结果:删除顶点v已经其相关的弧DFSTraverse(G,visit())初始条件:图G存在,visit的顶点的应用函数eaintheaccidentinvestigation,managementandreporting,eachpostshouldbedevelopedunderthissystemspecialistscheck,cleartheexaminations,time,cyclesandotherrelevantregulations.Strengtheningsitesupervisionandexamination,todetectandinvestigateillegalcommand,illegaloperationsandviolationsofoperatingrules.Secondsafetyreferstotheproductionsite,technologymanagement,equipment,facilities,andsooncanleadtoaccidentsrisksexist.1,accordingtotheextentofthesecurityrisks,solvingisdividedintoa,b,andclevelsofdifficulty;A-level:difficult,miningdifficulties,shallbereportedtothecompany'sproblems.B-class:difficulttoresolvedif听范读短文的录音。学生根据拼音自由朗读短文,不会拼读的音节求助同学或老师。听老师读短文,把自己不会认读的字和词听清楚。指名朗读,重点纠正“蓝”“绿”“帆”的读音。齐读短文,进一步熟悉短文。你最喜欢哪一句话?指导学生有感情地朗读。ficulties,shallconsistofminingorganizationstosolveproblems.C-class:fromsegmentsandbusinessrisksthatmustbeaddressedintheDepartment.2,open-pitmineunsafetypesinclude:electrical,transport,blasting,fire,andotherslope.3,accordingtotheseverityofthehazardfilledinbyunittroubleshooting,registrationform(seeatt操作结果:对图进行深度优先遍历,在遍历过程中对每个结点调用visit函数一次,一旦visit失败,则操作失败BFSTraverse(G,visit())初始条件:图G存在,visit的顶点的应用函数操作结果:对图进行广度优先遍历,在遍历过程中对每个结点调用visit函数一次,一旦visit失败,则操作失败}ADTGraph2、设定栈的抽象数据类型:ADTStack{数据对象:D={ai|ai∈CharSet,i=1,2,……,n,n≥0}数据关系:R1={ai-1,ai|ai-1,ai∈D,i=2,……,n}基本操作:InitStack(&S)操作结果:构造一个空栈S。DestroyStack(&S)初始条件:栈S已存在。操作结果:栈S被销毁。Push(&S,e);初始条件:栈S已存在。操作结果:在栈S的栈顶插入新的栈顶元素e。Pop(&S,e);初始条件:栈S已存在。操作结果:删除S的栈顶元素,并以e返回其值。StackEmpty(S)初始条件:栈S已存在。操作结果:若S为空栈,则返回TRUE,否则返回FALSE。}ADTStack3、设定队列的抽象数据类型:ADTQueue{数据对象:D={ai|ai属于Elemset,i=1,2….,n,n=0}数据关系:R1={ai-1,ai|ai-1,ai属于D,i=1,2,…,n}约定ai为端为队列头,an为队列尾基本操作:InitQueue(&Q)操作结果:构造一个空队列QDestryoQueue(&Q)初始条件:队列Q已存在。操作结果:队列Q被销毁,不再存在。EnQueue(&Q,e)初始条件:队列Q已经存在操作结果:插入元素e为Q的新的队尾元素DeQueue(&Q,&E)初始条件:Q为非空队列操作结果:删除Q的队尾元素,并用e返回其值QueueEmpty(Q)初始条件:队列已经存在eaintheaccidentinvestigation,managementandreporting,eachpostshouldbedevelopedunderthissystemspecialistscheck,cleartheexaminations,time,cyclesandotherrelevantregulations.Strengtheningsitesupervisionandexamination,todetectandinvestigateillegalcommand,illegaloperationsandviolationsofoperatingrules.Secondsafetyreferstotheproductionsite,technologymanagem

1 / 18
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功