Joel VanderWerf
11/30/2006 3:50:00 AM
Louis J Scoras wrote:
> On 11/29/06, Joel VanderWerf <vjoel@path.berkeley.edu> wrote:
>
>> Why isn't there an Array#classify, which would return a hash of arrays,
>> preserving duplicates?
>
> Beats me =) I'm not arguing against such a method; just pointing out
> that there's already something that might get the job done. A lot of
> times people use arrays to represent sets without realizing it.
I wasn't arguing either. I had forgotten about the useful Set#classify,
and thought why not have one for Array too? I can't see any theoretical
reason not to.
--
vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407