-
Notifications
You must be signed in to change notification settings - Fork 351
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Heap is broken with objects #23
Comments
any updates on this issue? |
@dirkholzapfel I ended up using https://github.com/rubyworks/pqueue instead |
If you let the elements not same, this err wont be raised.
But if you need elements to be same, just replace Heap with MaxHeap or MinHeap.
|
This Heap is slower very much than Ruby's built in Array sorting. I'm using Ruby 2.2.4. |
This is still the case. If you're here because Leetcode uses this as the algorithm library for Ruby, I'd suggest just directly copy pasting florian's rb_heap into the editor instead
|
Works when the heap length is < 10 but fails with 10+
RuntimeError: Couldn't delete node from stored nodes hash
The text was updated successfully, but these errors were encountered: