Method: Vector#collect

Defined in:
lib/matrix.rb

#collect(&block) ⇒ Object Also known as: map

Like Array#collect.



1775
1776
1777
1778
1779
# File 'lib/matrix.rb', line 1775

def collect(&block) # :yield: e
  return to_enum(:collect) unless block_given?
  els = @elements.collect(&block)
  self.class.elements(els, false)
end