RAA - each-sync

each-sync / 0.1.0

Short description: EachSynchronizer
Category: Library/Syntax
Status: just started.
Created: 2001-01-23 06:57:03 GMT
Last update: -
Owner: Okada -yun- Jun (Projects of this owner)
Homepage: http://www.nekome.net/ruby/index_en.html
Download: http://www.nekome.net/ruby/eachsynchronizer/eachsynchronizer-0.1.0.tar.gz
License: Ruby's
Dependency:
None
Description:

EachSynchronizer is library to synchronize mutiple objects' each method.

Example)

a = [58, 38, 6, 97, 26, 86]
b = "5\n19\n61\n60\n9\n30"
c = 50..60
prog = [a, b, c]

result = []

prog.synchronous_each do |args|
result << args.collect{|n| n.to_i}.max
end

p result
=> [58, 51, 61, 97, 54, 86]

Edit this project (for project owner)

back to RAA top