Skip to content

Add documentation for PairingHeap data structure#803

Open
krrishverma1805-web wants to merge 1 commit intotypelevel:masterfrom
krrishverma1805-web:add-pairingheap-docs
Open

Add documentation for PairingHeap data structure#803
krrishverma1805-web wants to merge 1 commit intotypelevel:masterfrom
krrishverma1805-web:add-pairingheap-docs

Conversation

@krrishverma1805-web
Copy link

What this PR does

Adds a documentation page for the PairingHeap data structure with runnable mdoc examples.

Why

PairingHeap is a key data structure in cats-collections with excellent empirical performance and an efficient O(1) merge operation. It currently has no documentation page, unlike Heap (which has binaryheap.md), Diet, Dequeue, Set, etc.

Contents

The new page covers:

  • What PairingHeap is and its theoretical background
  • Supported operations with complexity information
  • Comparison with the binary Heap to help users choose between them
  • Runnable mdoc examples: creation, add, remove, fromIterable, combine (merge), and takeLargest

Checklist

  • Follows existing documentation style (consistent with binaryheap.md, dequeue.md, etc.)
  • All mdoc examples compile successfully (sbt docs/mdoc — 0 errors)
  • Covers key operations with complexity annotations

@krrishverma1805-web
Copy link
Author

krrishverma1805-web commented Feb 27, 2026

@gemelen can you please review this..

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