Skip to content

feat: added binomial heap data structure#3188

Open
sarveshjoshi29 wants to merge 1 commit into
TheAlgorithms:masterfrom
sarveshjoshi29:add-binomial-heap
Open

feat: added binomial heap data structure#3188
sarveshjoshi29 wants to merge 1 commit into
TheAlgorithms:masterfrom
sarveshjoshi29:add-binomial-heap

Conversation

@sarveshjoshi29

Copy link
Copy Markdown

Description of Change

This PR adds a C++ implementation of the Binomial Heap (min-heap) data structure under the data_structures folder.
A binomial heap is a collection of binomial trees that supports the following operations : insertion, get-min, pop-min, and merging two binomial heaps in $O(\log n)$ time.
The implementation contains:

  • Full documentation obeying the Doxygen guidelines.
  • Self-test cases covering all operations and various edge cases (insertion order, duplicate values, popping, merging, and unifying heaps) with assertions.

Checklist

  • Added description of change
  • Added file name matches File name guidelines
  • Added tests and example, test must pass
  • Added documentation so that the program is self-explanatory and educational - Doxygen guidelines
  • Relevant documentation/comments is changed or added
  • PR title follows semantic commit guidelines
  • Search previous suggestions before making a new one, as yours may be a duplicate.
  • I acknowledge that all my contributions will be made under the project's license.

Notes: Adds a complete, self-tested, and documented implementation of the Binomial Heap to data_structures. This is also my first ever PR, I apologize if I have missed out anything, thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant