That is quite the bit of entirely-gratuitous “sleuthing” that you have done in order to solve this problem,
Arg! Actually, it wasn't that much; and it wasn't gratuitous. About 15 minutes effort total spread over the periods of inane pundit chatter between the events at the velodrome.
And the reason it was so simple is that the OP did all the right things:
- Provided self-contained code that ran straight out of the download.
- He provided clear instructions on how to run it to demonstrate the problem.
- He'd obviously cut it down considerably just for the purpose of posting.
That, combined with the clear, simply-structured code, made it easy to comment out one or two lines here or there to isolate where in the code the problem lay. And that is the essence of debugging -- finding the bug. After that it is just reasoning.
It is also where all the "let's hide the complexity behind yet another layer of abstraction" crowd fall flat on their faces. Their attempts to make things look simple, is their undoing when it comes to trying to track through that hidden complexity. Looks simple is not the same as is simple. And every layer of abstraction adds complexity, and removes none.
With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.