Results 1 to 1 of 1

Thread: building a tree

  1. #1
    vendetta is offline Member
    Join Date
    Jan 2010
    Posts
    31
    Rep Power
    0

    Default building a tree

    I am trying to make a class to build a basic binary tree. If we have a root as item #1, the next item added (#2) would be its left child. The next item added (#3) would be placed as the right child. The method would sense there are out of options and to go to the far left and use the next depth: Item #4 would be the left child of item #2 and item #5 would be the right child of #2 as well. This would just keep continuing as items are added. Is it possible to do this?
    Last edited by vendetta; 02-26-2010 at 09:32 PM.

Similar Threads

  1. Building to a .jar in Netbeans 6.7.1
    By Gregadeaux in forum New To Java
    Replies: 0
    Last Post: 12-14-2009, 03:00 AM
  2. Creating a Tree and then saving the Tree
    By jackmatt2 in forum New To Java
    Replies: 0
    Last Post: 08-22-2009, 12:51 PM
  3. ignore links when building file tree
    By itaipee in forum New To Java
    Replies: 1
    Last Post: 07-28-2009, 06:41 PM
  4. help needed regarding tree building
    By invincible_me in forum New To Java
    Replies: 2
    Last Post: 08-12-2008, 01:44 PM
  5. building a house
    By dc2acgsr99 in forum Java Applets
    Replies: 4
    Last Post: 03-07-2008, 11:18 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •