Link to home
Start Free TrialLog in
Avatar of curiouswebster
curiouswebsterFlag for United States of America

asked on

What is a binary tree and how does it work?

What is a binary tree and how does it work?

I am sure I worked with them years ago, but have forgotten the details.  I use Borland's Pascal Database Tools, which I think was binary tree.  Anyway, I never coded one and just want to be reminded of how they work...
SOLUTION
Avatar of javaftper
javaftper
Flag of Afghanistan image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of curiouswebster

ASKER

I was hoping for a simple explanation.  A sentence or two.

I see, in layman's language, the nodes are configured into a tree structure.  How are they traversed for maximum speed?

Does it divide the list and test the middle node to see which side of the list the target value is located?  Then split that side in half, etc.?
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I liked the visual example the best.  Thanks.