My £0.02:

Personally I learnt a lot more from tilly's post than merlyn's, because I had not thought about using END{}. Obviously this example (of a counter) could not be used in a 'real' site (no file locking etc) but then again I'm sure it would be better to just parse the Apache logfile than use any sort of counter.

When I'm at work I always think it's better to show people the 'long-hand' way of doing things before using shortcuts, because there will be times when shortcuts/modules are not available. (This is on AXE switches, not Perl, but you get the idea). If you teach someone a procedure and later they write their own script to automate it, then you know that they've really understood it.

Basically if people are only shown how to use the shortcuts, then after a while there will be no-one left who actually knows how to write the shortcuts in the first place.

JJ


In reply to Re: Re: Re (tilly) 3: One-Line Web Counter by jj808
in thread One-Line Web Counter by Jerry

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



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.