Would Give Gui Allows User Add Search Display Entire Tree Java Public Class Duplicate Publ Q37099461

How would you give this a GUI which allows the user to add,search and display the entire tree. Java

public class Duplicate {

   public TreeNode root;

   public static class TreeNode {
       TreeNode left;
       int item;

       TreeNode right;

       TreeNode(TreeNode left, intitem, TreeNode right) {
           this.left =left;
           this.item =item;
           this.right =right;
       }
   }

   public static class Duplicate_Nodes {

       int item;
       int count;

       public Duplicate_Nodes(int item,int count) {

           this.item =item;
           this.count =count;
       }
   }

   public void print() {

       if (root == null) {

      

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.