O'Reilly logo

C# Data Structures and Algorithms by Marcin Jamro

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Binomial heaps

Another kind of heap is a binomial heap. This data structure consists of a set of binomial trees with different orders. The binomial tree with order 0 is just a single node. You can construct the tree with order n using two binomial trees with order n-1. One of them should be attached as the left-most child of the parent of the first tree. It does sound a bit complicated, but the following diagram should remove any confusion:

As already mentioned, the binomial tree with order 0 is only a single node, as shown on the left. The tree with order 1 consists of two trees with order 0 (marked with the dashed border) connected to each ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required