Skip to content

aaded binary-heap-implementation.c - #1514

Closed
AayanSayyed wants to merge 1 commit into
TheAlgorithms:masterfrom
AayanSayyed:issue1496-binary-heap-algo
Closed

AayanSayyed wants to merge 1 commit into
TheAlgorithms:masterfrom
AayanSayyed:issue1496-binary-heap-algo

Conversation

@AayanSayyed

Copy link
Copy Markdown

Description of Change

This pull request introduces a implementation in C, addressing issue #1496
The Min Binary Heap is a fundamental data structure used to efficiently manage priority queues, scheduling algorithms, and graph-based shortest path computations such as Dijkstra’s algorithm.
The implementation provides clean, modular, and well-documented functions to perform essential heap operations with their optimal time complexities:

Operation Time Complexity
Insert O(log n)
Extract Min O(log n)
Search O(n)
Get Min (Peek) O(1)
Display O(n)

The implementation includes:

A dynamic array-based Min Heap
Functions for insertion, extraction, and heap property maintenance and heapifyDown
A sample main() demonstrating usage
Proper memory management and validation checks

References

Fixes issue: #1496

Checklist

Added a detailed description of change
File name : c/data_structure/binary_tree/binary_heap_implimentation.c
File Name Guidelines
Added example and test cases all tests pass successfully Included clear documentation and inline comments

@github-actions

Copy link
Copy Markdown
Contributor

This pull request has been automatically marked as abandoned because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions Bot added the Stale label Nov 26, 2025
@github-actions

github-actions Bot commented Dec 3, 2025

Copy link
Copy Markdown
Contributor

Please ping one of the maintainers once you commit the changes requested or make improvements on the code. If this is not the case and you need some help, feel free to ask for help in our Gitter channel or our Discord server. Thank you for your contributions!

@github-actions github-actions Bot closed this Dec 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant