chunk: performs 'group by' on an enumerable

Applies the block to each item in the collection, using the result as
the item's key. Returns a dictionary of arrays grouped by the set of
keys returned by the block.

    [@[@3, @1, @2] chunk:^(id num){
        if ([num integerValue] % 2 == 0) {
            return @"even";
        }
        else {
            return @"odd";
        }
    }];
    // => @{ @"even": @[@2], @"odd": @[@3, @1] }