Enumerable::Chain
Provides method chain for each items of Enumerable
Installation
Add this line to your application's Gemfile:
gem 'enumerable-chain'
And then execute:
$ bundle
Or install it yourself as:
$ gem install enumerable-chain
Usage
require "pp"
pp 10.times.<.(3).> #=> [0, 1, 8, 27, 64, 125, 216, 343, 512, 729]
pp 10.times.<.(4).>.select{|i| i>100}.<.to_s.length.> #=> [3, 3, 4, 4, 4, 4]
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request