摘要: 汉诺塔三阶代码 #汉诺塔问题.py n = int(input()) count = 0 def hanoi(n,a,b,c): global count if n == 1: print("将第{}个从{}搬到{}".format(1,a,c)) count += 1 else: hanoi(n- 阅读全文
posted @ 2020-03-30 21:41 L_Hjgg 阅读(119) 评论(0) 推荐(0) 编辑