算法与设计算法分析基础-整体框架.ppt
《算法与设计算法分析基础-整体框架.ppt》由会员分享,可在线阅读,更多相关《算法与设计算法分析基础-整体框架.ppt(33页珍藏版)》请在淘文阁 - 分享文档赚钱的网站上搜索。
1、算法与设计算法分析基础整体框架 Still waters run deep.流静水深流静水深,人静心深人静心深 Where there is life,there is hope。有生命必有希望。有生命必有希望Review of last classbHow to solve a problem by computerbThe notion of algorithmActual problemMathematics modelAlgorithm design and analysisProgrammingResult analysisInput output finiteness effect
2、iveness definitenessbAlgorithm design pattern2022/12/622010-2011-01 Design and Analysis of Algorithm SCUECHow to describe an algorithm?bNatural languageStep1 Input m and n.Step2 Divide m by n and assign the value of the remainder to r.Step3 If r=0,return the value of n as the answer and stop;otherwi
3、se,proceed to Step 4.Step4 Assign the value of n to m and the value of r to n.Step5 Go to Step2.Advantages:easy understandDisadvantages:exist inherent ambiguity2022/12/632010-2011-01 Design and Analysis of Algorithm SCUECHow to describe an algorithm?(II)bFlow chartStartr=0Input m and nr=m%nm=nn=rout
4、put nStopA flowchart is a method of expressing an algorithm by a collection of connected geometric shapes containing descriptions of the algorithms steps.Advantages:intuitiveDisadvantages:lack flexibility2022/12/642010-2011-01 Design and Analysis of Algorithm SCUECHow to describe an algorithm?(III)b
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 算法 设计 分析 基础 整体 框架
限制150内