when i run this with the "use strict use warnings" i get this:
Global symbol "$path" requires explicit package name at punctuation.pl + line 6.
...
what is an explicit package name? how do i delcare it?
Whenever perl gives you any warning or error message you are unsure of the meaning of, consult perldoc perldiag (or say use diagnostics;, which tries to do this for you).

In this case, it says:

(F) You've said "use strict vars", which indicates that all variables +must either be lexically scoped (using "my"), declared beforehand usi +ng "our", or explicitly qualified to say which package the global var +iable is in (using "::").
which would at least have told you about "our", and explained the wording of the error message (which certainly isn't worded as helpfully as it could be).

In reply to Re: Declaring variables under 'use strict' by ysth
in thread Declaring variables under 'use strict' by Yoda_Oz

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.