require 'transducers' class GameOfLife < Processing::App T = Transducers def random_data T.transduce(T.map{ rand(1000) < ALIVE_START }, :<<, [], 0..row * column) end end
require 'transducers' class GameOfLife < Processing::App T = Transducers def random_data T.transduce(T.map{ rand(1000) < ALIVE_START }, :<<, [], 0..row * column) end end
No comments:
Post a Comment