Class: Algorithmable::DataStructs::Heap::Min
- Inherits:
-
Imp
- Object
- Imp
- Algorithmable::DataStructs::Heap::Min
- Defined in:
- lib/algorithmable/data_structs/heap/min.rb
Instance Method Summary collapse
-
#initialize(collection = []) ⇒ Min
constructor
A new instance of Min.
Constructor Details
#initialize(collection = []) ⇒ Min
Returns a new instance of Min.
5 6 7 8 9 |
# File 'lib/algorithmable/data_structs/heap/min.rb', line 5 def initialize(collection = []) super(collection) do |this, other| (this <=> other) > 0 end end |