求二叉树的深度

时间:2014-12-12 14:53:45
【文件属性】:
文件名称:求二叉树的深度
文件大小:3KB
文件格式:CPP
更新时间:2014-12-12 14:53:45
二叉树的深度 采用先序法建立一棵二叉树,设计求该二叉树的深度,二叉树的数据域类型为字符型, 扩展二叉树的叶子结点用‘#’表示,要求可以求多棵二叉树的深度,当二叉树的深度为0时程序结束。

网友评论

  • 方法一在G++下会有 错误信息: c:TeachingJudgerTempmain.cpp: In member function "int bitree::Depth(binode*)": c:TeachingJudgerTempmain.cpp:69:37: error: "exit" was not declared in this scope