SPUG:Yitzchak makes Quiz of Week!

Tim Maher tim at consultix-inc.com
Wed May 28 15:47:33 CDT 2003


Here's the latest Perl Quiz of the Week, from Mark-Jason Dominus.
Note that SPUGster Yitzchak is featured! 

Yitzchak, enjoy your 15 minutes of fame; the clock is ticking! 8-}

-Tim
P.S. Email perl-qotw-subscribe at plover.com to subscribe.
=======================================================
| Tim Maher, Ph.D.            tim(AT)timmaher.org     | 
| JAWCAR ("Just Another White-Camel Award Recipient") |
| SPUG Founder & Leader       spug(AT)seattleperl.org |
| Seattle Perl Users Group    www.seattleperl.org     |
=======================================================

The 'MH' mail system stores email messages in a 'folder', which is
just a plain directory.  Messages are files in this directory whose
names are numerals.  The directory might contain other files or
subdirectories; these are not messages.

The 'scan' command summarizes the contents of a folder.  Here's a
typical output:

 1349  03/22 Yitzchak Scott-Th  Re: Hey, is this list alive?<<On Sat, 22 Mar 20
 1350  03/23 To:perl-qotw-disc  Re: Hey, is this list alive?<<On Thu, 20 Mar 20
 1351  03/24 Kieran             <joke> Proposed advanced problem for this week.
 1352  03/25 John_Wunderlich at C  Re: Hey, is this list alive?<<This is a multipa
 1353  04/16 "Sparrow, Dave"    QOTW 10 [SPOILER]<<This message is in MIME form
 1354  05/24 Shlomi Fish        Post Mortem for Perl QOTW #8 (Graham's Function
 1355  05/24 Shlomi Fish        Post Mortem for Expert QOTW #8 (Graham's Functi
 1356  05/24 To:Shlomi Fish     Re: Post Mortem for Perl QOTW #8 (Graham's Func

The output contains one line for each message.  It includes the
message number (filename of the message file), date sent, sender (or
recipient, if the sender is me), the subject, and as much of the body
as will fit (as in message 1353, above.)  Messages are always listed
in numerical order.

Implement a 'scan' command.  It gets one required argument, which is
the path to the folder directory.  (The real 'scan' command is a
little different, but that's not important today.)

I won't be sending a postmortem on Monday, because I will be in Hawai`i.
(See http://www.geekcruises.com/home/pw3_home.html )  
I will send one when I get back, probaly on June 16.

-Tim
*------------------------------------------------------------*
| Tim Maher (206) 781-UNIX  (866) DOC-PERL  (866) DOC-UNIX   |
| CEO, JAWCAR ("Just Another White Camel Award Recipient")   |
| tim(AT)Consultix-Inc.Com  TeachMeUnix.Com  TeachMePerl.Com |
*+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-*
|  Watch for my Book: "Minimal Perl for Shell Programmers"   |
*------------------------------------------------------------*



More information about the spug-list mailing list