会员
周边
新闻
博问
AI培训
云市场
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
西西嘛呦
从自己能做到的开始,一件件来,缓慢而坚定地前进,尽力而为
博客园
首页
新随笔
联系
管理
2021年1月17日
【python刷题】二叉树-相关题目
摘要: 计算二叉树有多少个节点 def count(root): if not root: return 0 return 1 + count(root.left) + count(root.right) 计算二叉树的深度 def count_depth(root): if not root: return
阅读全文
posted @ 2021-01-17 11:34 西西嘛呦
阅读(199)
评论(0)
推荐(0)
编辑
公告