Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

comment on

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

Further to Anonymonk's point:

>perl -wMstrict -le "use Data::Dump; ;; my $sheet = { qw(F29 foo G30 bar) }; dd $sheet; ;; my %sheet; ;; print qq{'$sheet->{F29}'}; print qq{'$sheet{G30}'}; " { F29 => "foo", G30 => "bar" } 'foo' Use of uninitialized value $sheet{"G30"} in concatenation (.) or strin +g at -e line 1. ''

Do you see how the expressions  $sheet->{F29} and  $sheet{G30} access two completely different structures, one of which is empty?

... I can make no sense of the order in which it displays contents.

A hash has no internal "order" except for the pairing of each unique key with its value. Access to and listing of hash keys, values and key/value pairs is (apparently) random. (Update: Don't be mislead by the fact that the order in the dump displayed above matches the order of initialization of the hash reference example: this is entirely adventitious. The dump of a larger hash structure will show greater disorder — but again, a key always cleaves to its value.)


In reply to Re^10: Iterating Through Cell Blocks with Spreadsheet::Read by AnomalousMonk
in thread Iterating Through Cell Blocks with Spreadsheet::Read by Hammer2001

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 admiring the Monastery: (6)
As of 2024-03-29 13:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found