#include<iostream>
#include<stdlib.h>
using namespace std;
template <class T>
struct BinaryTreeNode
{
BinaryTreeNode(const T& data)
:_data(data)
, _left(NULL)
, _right(NULL)
{
}
BinaryTreeNode<T>*_left;
BinaryTreeNode<T>*_right;
T _data;
};
template<class T>
class BinaryTree
{
public:
typedef BinaryTreeNode<T> Node;
BinaryTree()
:_root(NULL)
{
}
Node
二叉树求最短路径
最新推荐文章于 2023-05-10 10:10:00 发布