Go Back   Computer Forums > Welcome To Computer Forums .org > Social Lounge | Off Topic
Click Here to Login
Join Computer forums Today


Reply
 
Thread Tools Search this Thread Display Modes
 
Old 11-16-2006, 06:35 PM   #1
In Runtime
 
Renegadeandy's Avatar
 
Join Date: Apr 2006
Posts: 291
Send a message via MSN to Renegadeandy
Default Serious Question

Hi guys.

Im currently trying to program a Binary tree in java.

Now - this implementation must be fully recursive. Do you think a set of N should be used for this problem?

I have been thinking about it for quite some time - other than that - all i can see if some sort of log n arithmetic.

I wondered if i could possibly even use the schlagelhoch tree balancing algorithm but this doesnt use a set of N, shoud i perhaps try using a bubblesort on a set of X instead?

Any ideas?

Thanks
__________________

__________________
Referred to by : UK31337

Visit http://www.pens2paper.com - For Your Stationery Needs!
Renegadeandy is offline   Reply With Quote
Old 11-16-2006, 07:12 PM   #2
Fully Optimized
 
UK31337's Avatar
 
Join Date: Feb 2005
Posts: 2,776
Default Re: Serious Question

You need to take the root, insert it into both left and right node, and then assign the whole new array to the set of N.

Then, you can perform the binary search (ie log n) on the set of N, which will give you a balanced AVL tree.

The set of X is only used when you're deleting the contents of a map, idiot Even then, it's not CPU efficient, the Bjuren-Cooper bubblesort inverse insertion algorithm is so much faster.
__________________

__________________
Master of common sense. If you don't like it, stop reading.
UK31337 is offline   Reply With Quote
Old 11-17-2006, 08:12 AM   #3
In Runtime
 
Renegadeandy's Avatar
 
Join Date: Apr 2006
Posts: 291
Send a message via MSN to Renegadeandy
Default Re: Serious Question

How, the Bjuren-Cooper bubblesort inverse insertion must traverse the set of n squared...

Are you sure that the set of n actually parses the integer complexity by 2 dp the stack overflow seems to represent this fairly methodically.

The set of x can be used in more than the deleting contents of a map - god what a frickin noob. I have used it more than 8 times on the linton-ionosphere cakeeater algorithm so i really dont know what you mean - it looks like this so fair

a[i] for x = a to bjuren{

n.setof(x) +-%67.

Any ideas?
__________________
Referred to by : UK31337

Visit http://www.pens2paper.com - For Your Stationery Needs!
Renegadeandy is offline   Reply With Quote
Old 11-17-2006, 08:16 AM   #4
Golden Master
 
Raffaz's Avatar
 
Join Date: Sep 2006
Posts: 6,798
Send a message via AIM to Raffaz Send a message via MSN to Raffaz Send a message via Yahoo to Raffaz
Default Re: Serious Question

Pure BS lol
Raffaz is offline   Reply With Quote
Old 11-17-2006, 08:29 AM   #5
In Runtime
 
Renegadeandy's Avatar
 
Join Date: Apr 2006
Posts: 291
Send a message via MSN to Renegadeandy
Default Re: Serious Question

excuse me?

that is proper java syntax for the binary tree declaration.....
please dont insult my work if you dont know what you are talking about please dont answer.

Thanks.
__________________
Referred to by : UK31337

Visit http://www.pens2paper.com - For Your Stationery Needs!
Renegadeandy is offline   Reply With Quote
Old 11-17-2006, 09:01 AM   #6
Golden Master
 
Raffaz's Avatar
 
Join Date: Sep 2006
Posts: 6,798
Send a message via AIM to Raffaz Send a message via MSN to Raffaz Send a message via Yahoo to Raffaz
Default Re: Serious Question

Ha ha ya right, thought ya were taking the piss lol. Just googled it
Raffaz is offline   Reply With Quote
Old 11-17-2006, 09:11 AM   #7
In Runtime
 
Renegadeandy's Avatar
 
Join Date: Apr 2006
Posts: 291
Send a message via MSN to Renegadeandy
Default Re: Serious Question

Mind showing me the code result for the google search then mr - would love to see it.
__________________
Referred to by : UK31337

Visit http://www.pens2paper.com - For Your Stationery Needs!
Renegadeandy is offline   Reply With Quote
Old 11-17-2006, 09:34 AM   #8
Golden Master
 
Raffaz's Avatar
 
Join Date: Sep 2006
Posts: 6,798
Send a message via AIM to Raffaz Send a message via MSN to Raffaz Send a message via Yahoo to Raffaz
Default Re: Serious Question

found ya bubblesort, thats only part i checked mr
http://www.ece.unb.ca/brp/lib/java/bubblesort/
Raffaz is offline   Reply With Quote
Old 11-17-2006, 09:37 AM   #9
Fully Optimized
 
Zer0Cool's Avatar
 
Join Date: Aug 2006
Posts: 1,599
Default Re: Serious Question

hahah looks like complete Gibberish 2 me
__________________

__________________
- Asus P6T Deluxe v2 - Intel i7 920 @4Ghz 1.35v- Prolimatech HS - Cosmos S Case -
- ABS Tagan BZ Series BZ800 PSU
- ATI 5870 - G.SKILL 6GB DDR3 1600 - Razer Barracuda™ AC-1
- 120GB Crucial C300 SSD & 3X WD640AAKS HDD
- Dell 24" 2408WFP & 2407WFP-HC Monitor
Zer0Cool is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off



All times are GMT -5. The time now is 08:01 PM.


Powered by vBulletin® Version 3.8.8 Beta 4
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO 3.6.0