图形环境下的汉诺塔演示  被引量:4

Demo on Hanoi Tower in graphical environment

在线阅读下载全文

作  者:卫洪春[1] 

机构地区:[1]四川文理学院计算机科学系,四川达州635000

出  处:《电子设计工程》2014年第15期8-10,14,共4页Electronic Design Engineering

基  金:国家自然科学基金(61152003);四川省青年基金(10ZB085)

摘  要:经典的汉诺塔问题的求解主要是采用递归算法来实现。但是在不同的语言开发环境下,其求解过程主要是以控制台模式的字符方式来显示算法的运算结果。基于控制台模式下移动汉诺塔的运算结果虽然正确,但存在感观上不直观的原因,文中提出了在图形环境中显示移动汉诺塔运算结果的观点,采用了面向对象的程序设计思想和传统的递归程序设计方法,结合图形环境中相关的绘图知识,使移动汉诺塔的运算过程更形象、更直观,达到了更好的可视化演示效果。The methods for solving the classical problem on Hanoi Tower is mainly used to adopt recursive algorithm at present.However,in different development environments,its solving process is to display operating results mainly based on the character mode in console mode.In console mode, although the operating result of moving Hanoi Tower is correct,it is not intuitive. This article presents the view of displaying the operating results in graphical environment , adopt object-oriented programming concepts and traditional recursive programming method, combine related drawing knowledge of graphical environment.It makes the operating process more vivid, more intuitive,and achieves a better visual demonstration effect.

关 键 词:汉诺塔 递归 图形 C++ 

分 类 号:TN919[电子电信—通信与信息系统]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象