>>>>> "JSD" == Jonathan Scott Duff <[EMAIL PROTECTED]> writes:

JSD> On Wed, Aug 16, 2000 at 12:48:12PM -0400, Dan Sugalski wrote:
>> At 11:09 AM 8/16/00 -0400, John Porter wrote:
>> >The difference between numbers and strings is analogous to --
>> >or, on further reflection, IDENTICAL to -- the difference between
>> >arrays and associative arrays.  (The former are numerically indexed,
>> >the latter indexed by strings.)
>> 
>> The analogy doesn't hold. And people treat arrays and hashes *very* 
>> differently, far more so than the trivial differences in the notation might 
>> lead you to believe.

JSD> Could you come up with concrete examples that illustrate this point?
JSD> What would stop people from treating arrays and hashes differently if
JSD> the trivial notational differences are removed?

In a hash exists() is a valid concept. In an array (even a sparse one)
exists() has no meaning. The data is always there. The sparsity is
an implementational detail.

A hash has symbols, names, things. An array has just numbers[*].


<chaim>
[*] Anyone remember "Secret Agent Man", "they given you a number and 
    takin' way your name.

    What was the name of the show? "Secret Agent"? And what came first
    the song or the show?

    What was the real theme song? The title song was never played during
    the show, there was a different song played.

-- 
Chaim Frenkel                                        Nonlinear Knowledge, Inc.
[EMAIL PROTECTED]                                               +1-718-236-0183

Reply via email to