answersLogoWhite

0

Searching is slower for linked-lists rather than (ordered) trees because you need to iterate through each element serially, whereas for an ordered (binary) tree you use a "divide and conquer", otherwise known as binary search, method.

Think of it this way. Think of a number between 1 and 128. Perhaps the number is 97. With an ordered list, it would take 97 comparisons to find the item. With an unordered list, it would take an average of 64 comparisons - if the order was random. With a binary tree, i.e. a binary search, you only need 7 comparisons. In fact, you never need more than 7 comparisions for a tree size of 128, and on average, you would use less than that.

User Avatar

Wiki User

15y ago

What else can I help you with?

Related Questions

How fast do Thuja trees grow compared to other types of trees?

Thuja trees, also known as arborvitae, generally grow at a moderate rate compared to other types of trees. They are considered to have a medium growth rate, typically reaching a height of 10-15 feet in 5-7 years. This growth rate is slower than some faster-growing trees like poplars or willows, but faster than slower-growing trees like oaks or maples.


How fast does a cherry tree grow compared to other types of trees?

Cherry trees typically grow faster than many other types of trees, reaching maturity in about 15-20 years. This is faster than some hardwood trees like oak or maple, but slower than faster-growing trees like poplar or willow.


What is the practical application for a binary converter?

The reason that binary trees are used more often than n-ary trees for searching is that with every contract with an n-ary tree you can eliminate most of it.


Which tree grows faster coniferous or deciduous?

In general, coniferous trees tend to grow slower than deciduous trees. Coniferous trees typically have a slower growth rate due to their needle-like leaves, which have a smaller surface area for photosynthesis compared to the broad leaves of deciduous trees.


Why do coral grow slower?

Slower than what?


Why is the Lamborghini Murcielago slower?

Slower than what?


What is faster than a bird but slower than a snail?

nothing. that is impossible because if it is faster than a bird, then it isn't slower than a snail. and if it is slower than a snail, then it isn't faster than a bird.


How does a shark behave when it is sad?

it swims a little slower than normal it swims a little slower than normal it swims a little slower than normal


Slower than a canter?

A pace slower than a canter is a trot. In equestrian terms, the trot is a two-beat gait where the horse's legs move in diagonal pairs. It is faster than a walk but slower than a canter.


What is faster a lambergini or Ferrari?

a lamborghini is slower than a ferrai a lamborghini is slower than a ferrai


Can electrons move slower than the speed of light?

They can ONLY move slower than the speed of light.


What are the key differences between BST and AVL trees in terms of their structure and performance?

BST (Binary Search Tree) and AVL (Adelson-Velsky and Landis) trees are both types of binary trees used for storing and searching data. The key difference lies in their structure and performance. BSTs are simple binary trees where each node has at most two children, and the left child is smaller than the parent while the right child is larger. This structure allows for efficient searching, insertion, and deletion operations. However, if the tree is not balanced, it can degrade into a linked list, leading to slower performance. On the other hand, AVL trees are a type of self-balancing binary search tree where the heights of the two child subtrees of any node differ by at most one. This balancing property ensures that the tree remains relatively balanced, leading to faster search, insertion, and deletion operations compared to BSTs. However, maintaining this balance requires additional overhead, making AVL trees slightly slower in terms of performance compared to BSTs for some operations.