•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Computer Science and Software Design section within the Software Development category of DaniWeb, a massive community of 456,468 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,780 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Computer Science and Software Design advertiser: Programming Forums
Views: 1354 | Replies: 1
![]() |
•
•
Join Date: May 2006
Posts: 17
Reputation:
Rep Power: 3
Solved Threads: 0
If I were to implement a heap constructed of integer values, does it matter that the root is not the smallest value? In my algorithm book it always shows the root being the smallest value given. But the Wiki entry shows the root as being the largest value.
>does it matter that the root is not the smallest value?
If you designed it to be then yes, because that's a bug in your implementation. But as you describe the problem, your book is showing a min heap and the wiki article is showing a max heap. Both are variations of the heap priority property.
If you designed it to be then yes, because that's a bug in your implementation. But as you describe the problem, your book is showing a min heap and the wiki article is showing a max heap. Both are variations of the heap priority property.
I'm here to prove you wrong.
![]() |
•
•
•
•
•
•
•
•
DaniWeb Computer Science and Software Design Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
applications blog business software computer data database dell design development erp systems firefox government hardware india intel internet it java linux media microsoft mmorpg msdn networking news office online open open-source operating pricing programming project management rss science security software software selection source storage sun super system technology evaluation vista web wiki windows xp
- disposing of a large data structure.... (C++)
- a question about heap data structure (C)
- Data Structure Using JAVA (Java)
- How to delete a data structure in Builder 6.0? (C++)
- Discrete Math or Data structure (Computer Science and Software Design)
Other Threads in the Computer Science and Software Design Forum
- Previous Thread: J2ME help
- Next Thread: grandfathers rule



Linear Mode