Sha256: 6dc54a5afbf78e4669dc83db8613ca5b5e781afffd5b61a6a544c7253331960b

Contents?: true

Size: 179 Bytes

Versions: 5

Compression:

Stored size: 179 Bytes

Contents

module Enumerable
  def map_slice(num, &block)
    result = []
    each_slice(num) { |element| result << yield(element) }
    result
  end unless method_defined?(:map_slice)
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
space-0.0.8 lib/core_ext/enumerable/map_slice.rb
space-0.0.7 lib/core_ext/enumerable/map_slice.rb
space-0.0.6 lib/core_ext/enumerable/map_slice.rb
space-0.0.5 lib/core_ext/enumerable/map_slice.rb
space-0.0.4 lib/core_ext/enumerable/map_slice.rb