- 1
- 0
- 约1.05万字
- 约 37页
- 2019-11-28 发布于广东
- 举报
* 2005 a. int BiTreeDepth(BiTree T) { int ldepth, rdepth; if ( !T ) return -1; ldepth = BiTreeDepth ( T-lchild ) ; rdepth = BiTreeDepth ( T-rchild ) ; if ( ldepth = rdepth ) T-depth = ldepth+1; else T-depth = rdepth+1; return T-depth; } ? ? ? b. Status BiTreeBalance(BiTree T) { int ldepth, rdepth; if ( T==NULL ) return TRUE; if (T-lchild) ldepth = T-lchild-depth; else ldepth = -1; if (T-rchild) rdepth = T-rchild-depth; else rdepth = -1; lrdepth = ldepth – rdepth; if ( ( lrdepth == 0 || lrdepth == 1 |
您可能关注的文档
最近下载
- 锅炉日常运行记录表.docx VIP
- 新闻宣传培训课件.pptx VIP
- 2026年医卫类执业兽医-临床科目(全科)参考题库含答案解析(5套题答案).docx VIP
- GBT50493-2019石油化工可燃气体和有毒气体检测报警设计标准(完整正版清晰无水印)OCR.pdf VIP
- 远洋渔业无人机辅助探鱼、渔场环境监测应用与经济效益分析.docx VIP
- 职业兽医师试题及答案.docx VIP
- 中投顾问:2026-2030年中国固态电池行业深度分析报告.pdf VIP
- 中级会计实务教材电子书 -中级实务电子教材.docx VIP
- 安徽省合肥市庐阳区45中学2026届中考三模英语试题含答案.doc
- 简体中文版 ACI 318-14 结构混凝土建筑规范 及 解说 4.pdf VIP
原创力文档

文档评论(0)