Sha256: 90734273c527a1f6c090db3cd6795ff44a3f19d25ed789bd116184210987eeee
Contents?: true
Size: 238 Bytes
Versions: 6
Compression:
Stored size: 238 Bytes
Contents
class Array # Like <tt>Array#detect</tt>, but returns the calculated value def grab(&blk) result = each do |element| value = yield element break value if value end return if result == self result end end
Version data entries
6 entries across 6 versions & 1 rubygems