Last active
August 29, 2015 14:02
-
-
Save Bouke/3dad30b8c7d2b9408b8d to your computer and use it in GitHub Desktop.
Binary Heap (Priority Queue) in Swift
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This code was written when Swift didn't have access modifiers. Both
var heapandfunc heapifyare not part of the public API. You can onlypopitems onto the heap, so the result should always be a valid binary heap.