I realize this was posted with good intent as a learning experience/game for us here at Perl monks, but I have very mixed feelings about this post.
On one hand, I view coding as a responsibility. The number of people who know how to use code far outnumber the number of people who know how to write even bad code. The number of people who know how to write code (bad or good) far outnumber the the number of people who know how to scan code for errors or security risks. Those of us who know how to code have a responsibility to either (a) post in a forum where we can be easily critiqued or (b) post code that has been throughly tested. From that perspective, if you post bad or careless code on an isolated blog, you deserve what you get.
On the other hand, a rule of thumb I use when I criticize anyone in terms that are even remotely identifiable is "Can I say it to their face?". If I can't do that, I feel I don't have the right. When I saw this post, my first thought was to email the person and say here is some feedback you can learn from, but then I couldn't think of a way to say it that wouldn't run the risk of embarrassing him. So, for me, at least,it failed the 'can I say it to his face' rule. Maybe not though for others - I may just lack the creative tact needed. The only other option, keeping the author totally anonymous, would have been wrong. No matter how bad the code is, there are copyright and plagiarism issues with extensive unattributed quotes.
I just felt I needed to share that.
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:
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, 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, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
| & || & |
| < || < |
| > || > |
| [ || [ |
| ] || ] ||