[algogeeks] Java Algorithms and Data-structures Library

2008-06-30 Thread Wes Jossey
Morning Everyone: I'm currently creating a Java library that contains a collection of interfaces, abstract classes, and fully implemented versions of an assortment of data-structures and algorithms. The library is going to be used in conjunction with a program I'm writing, and its primary

[algogeeks] which data structure?

2008-06-30 Thread Vandana
Hello All, I would like to implement a tree with the following properties. 1. The tree is balanced. 2. Each node has a max of 7 sub nodes and min of ceil(7/2) sub nodes. 3. Number of nodes known from the beginning. How would I implement this? Is there a data structure that I can use? Consider

[algogeeks] Re: which data structure?

2008-06-30 Thread Venkatraman S
what did you try before you ask it in the forum? Is this part of your homework? Venkat On Mon, Jun 30, 2008 at 8:35 PM, Vandana [EMAIL PROTECTED] wrote: Hello All, I would like to implement a tree with the following properties. 1. The tree is balanced. 2. Each node has a max of 7 sub

[algogeeks] Re: which data structure?

2008-06-30 Thread Nat Padmanabhan
I guess I am not giving away too much if it is part of a homework but think along the lines of B-Tree with order 6. On Mon, Jun 30, 2008 at 11:07 AM, Venkatraman S [EMAIL PROTECTED] wrote: what did you try before you ask it in the forum? Is this part of your homework? Venkat On Mon, Jun

[algogeeks] Re: which data structure?

2008-06-30 Thread Vandana
Hi, I have used arrays and I have implemented 'Case 1' that I have explained in my example. Now I want to optimize it. To optimize the code I was thinking of B- trees. But the nodes dont have any unique identifier. It can be thought of as an employee hierarchy tree where only the affliation to

[algogeeks] Re: which data structure?

2008-06-30 Thread Nat Padmanabhan
B-trees don't need any special node identifiers, as long as there is some ordering in the data you should be fine. For employees, names are not a bad idea - you are going to have dupes but that can be handled. On Mon, Jun 30, 2008 at 11:14 AM, Vandana [EMAIL PROTECTED] wrote: Hi, I have used

[algogeeks] Re: which data structure?

2008-06-30 Thread Vandana
Ok thanks, employee hierarchy was just an example. I forgot that b- trees dint need a id. Thanks a lot. On Jun 30, 11:20 am, Nat Padmanabhan [EMAIL PROTECTED] wrote: B-trees don't need any special node identifiers, as long as there is some ordering in the data you should be fine. For