At 11:46 PM 8/15/00 -0400, Stephen P. Potter wrote:
>Lightning flashed, thunder crashed and Dan Sugalski <[EMAIL PROTECTED]> whispered:
>| > > Doesn't it make more sense to get rid of arrays and just use hashes?
>| >
>| >I guess it depends on what you think makes sense; but it seems to me
>| >that an array is a more fundamental data type; that it's easier (i.e.
>| >more efficient) to build associative arrays from arrays, than vice versa.
>|
>| It's silly to throw either of them out. Perl might be many things, but a
>| reductionist language it ain't...
>
>Why is it silly?  Hashes and arrays are *conceptually* very similar (even
>if they are extremely different implementation-wise).

It's because they've got so different an implementation, and their 
performance characteristics are so different.

They're also conceptually distinct. While there is a lot of overlap, 
there's also a rather large area of difference. While you can fake one with 
the other, it doesn't mean you should.


                                        Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to