ReePrime
Ruby's Enumerable Module: The Inject Method

Hosted by Dailymotion. For legal issues report at the Copyright Center, report us on DMC, or use the Instant Removal tool.

Ruby's Enumerable Module: The Inject Method

T
teachmetocode

84 Views • Jul 16, 2010

Description

The inject method is useful for aggregating data across a dataset. For example a summation could be done with inject (by aggregating each number into the sum.)