沒有人知道如何將值保存到左側或右側的二叉樹中? 比如我們有2層結構: struct A
{
int a;
struct A *left;
struct A *right;
}
struct B
{
A *root;
}
,我們有一個功能: void insert(B *tree, int value)
{
if(tree== NU
如何發送(node.data)SortTree類到TreePrinter然後用於打印樹。 import javax.swing.tree.TreeNode;
public class SortTree {
static Node root;
TreePrinter type =new TreePrinter();
class Node<A extends Comparable>{