Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Having probably instigated this with my use of the term today :), I was browsing over wikipedia entries while eating lunch and trying to come up with my take. I think that you're getting at the distinction here: Perl has associative arrays (an abstract datatype) which are implemented on top of hash tables (a more concrete datatype; which of course explains the colloquial usage of calling them "hashes"). However neither of these two guarantees nor provides any intrinsic ordering of keys. Were the associative arrays implemented on top of something else instead (say some sort of binary search tree, or an assoc list with new items added in sorted order rather than just prepended) the underlying implementation would then provide an intrinsic ordering of keys and then Perl's associative arrays could be said to be ordered (and probably wouldn't be called hashes . . . :).

So yeah, "unordered" is probably a better description than "unsorted".

The cake is a lie.
The cake is a lie.
The cake is a lie.


In reply to Re^2: What makes an array sorted and a hash unsorted? by Fletch
in thread What makes an array sorted and a hash unsorted? by ikegami

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (5)
As of 2024-04-24 19:08 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found