1 package com.wwj.cn; 2 3 //定义树节点 4 public class TreeNode { 5 6 int val; 7 TreeNode leftchild; 8 TreeNode rightchild; 9 10 public TreeNode(int data) { 11 this.val = data; 12 } 13 }
时间: 2024-11-07 07:16:39
1 package com.wwj.cn; 2 3 //定义树节点 4 public class TreeNode { 5 6 int val; 7 TreeNode leftchild; 8 TreeNode rightchild; 9 10 public TreeNode(int data) { 11 this.val = data; 12 } 13 }