ouch, those comments hurt my eyes! consider using the __END__ marker and you can follow with all the free text you want.
# Lines 4 and 5 are good Perl practice. "strict" and "warnings" are p
+ragmas
# that help prevent Perl programmers from doing silly things in their
+programs.
#
becomes
__END__
Lines 4 and 5 are good Perl practice. "strict" and "warnings" are pra
+gmas
that help prevent Perl programmers from doing silly things in their pr
+ograms.
<code>
<p>also, you might consider using here documents rather than multiple
+print statements.</p>
<code>
print OUT "For unique files in OldInventory.txt:\n";
print OUT "IGNORING FILES WITH Tmp OR Temp IN PATHNAME.\n";
print OUT "IGNORING FILES IN THE RECYCLE BIN.\n";
print OUT "IGNORING ALL HISTORY FILES.\n";
print OUT "LOWERCASING ALL FILE AND PATHNAMES BEFORE COMPARING.\n";
print OUT "\n";
becomes clearer, and more maintainable as
print OUT <<EOT;
For unique files in OldInventory.txt:
IGNORING FILES WITH Tmp OR Temp IN PATHNAME.
IGNORING FILES IN THE RECYCLE BIN.
IGNORING ALL HISTORY FILES.
LOWERCASING ALL FILE AND PATHNAMES BEFORE COMPARING.
EOT
it's one more useful concept to teach a user, and not difficult to understand.
-
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.
|