摘要
递归算法是教学中的难点。为了更好地帮助学生理解递归调用的过程,必须要构建形象直观的案例。本文采用Python语言的Turtle画图方法来绘制分形图,并通过分形图来形象地阐述递归函数的执行过程,学生可从图形的生成过程看出递归函数的执行顺序。实践结果表明,采用该案例获得了很好的教学效果。
Recursive algorithm is a difficult point in teaching.In order to better help students understand the process of recursive invocation,we must build visual cases.This paper uses the turtle drawing method of Python language to draw fractal graphs,and vividly describes the execution process of recursive functions through fractal graphs.Students can see the execution sequence of recursive functions from the generation process of graphs.The practical results show that the case has achieved good teaching results.
作者
陈欣
CHEN Xin(Department of Computer Engineering,Zhicheng College,Fuzhou University,Fuzhou,China,350002)
出处
《福建电脑》
2022年第9期67-70,共4页
Journal of Fujian Computer