Perl

Menu

Homework 5 Output

The following output is acheived by executing your script as follows:

./hw5.pl --url http://www.cs.rpi.edu/~lallip/perl/fall05/hw5sample.html --file saved.txt --debug --email joe@example.com

Debugging Output

Now getting 'http://www.cs.rpi.edu/~lallip/perl/fall05/hw5sample.html'
'http://www.cs.rpi.edu/~lallip/perl/fall05/hw5sample.html' retrieved
Now opening saved.txt for writing
saved.txt opened for writing
About to begin substituting
substitutions complete, found 24 numbers
Numbers: 5 1 5 1 25 5.001 84 2954 -43.1 +952.00001 1 3997 3998 3999 2
12 43 29 2005 2 12 56 04 2005
File closed
Now verifying 'joe@example.com'
Now sending summary to 'joe@example.com'
Message composed, now sending
Email sent to 'joe@example.com'

Modified File

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
  <head>
    <title>Sample Homework V file</title>
  </head>

  <body>
    <hI>Sample Homework V file</hI>
    <p>This is a file designed to have many numbers;  for example,
    each of the following should be replaced:
      XXV, V, LXXXIV, MMCMLIV<br />
      XLIII, CMLII
    </p>
    <p>There is also at least I comment down below that has a bunch of
    numbers - don't forget to check them!</p>
    <p>Just for good measure, here's a few more: MMMCMXCVII,
    MMMCMXCVIII, MMMCMXCIX</p>


    <hr>
<!-- Created: Wed Nov  II XII:XLIII:XXIX EST MMV -->
<!-- hhmts start -->
Last modified: Wed Nov  II XII:LVI:IV EST MMV
<!-- hhmts end -->
  </body>
</html>

Emailed Results

We successfully parsed 'http://www.cs.rpi.edu/~lallip/perl/fall05/hw5sample.html'. We found and replaced 24 numbers, the largest of which was 3999, and the least of which was -43.1. The substitution was performed on November 2, 2005 3:56PM.
Perl Quotes
Perl Quotes