Pathologically Eclectic Rubbish Lister | |
PerlMonks |
Positional Pattern-Matchingby blink (Scribe) |
on Sep 24, 2002 at 01:19 UTC ( [id://200272]=perlquestion: print w/replies, xml ) | Need Help?? |
blink has asked for the wisdom of the Perl Monks concerning the following question:
What I'd like this code-snippet to do, is match "Schedule: Full" or "Schedule: CINC" with whatever day of week/time is associated with that particular schedule. I've hacked something together, although not elegant, that will, at least, grab the first and second match of "Schedule:". For the life of me, I can't figure out how to grab the day of week and time. Here's the code:
If I ran this program in it's completed state today (Monday), it would return: "Sunday 02:00:00" I suppose that I could populate an array with "days of week" and test "today" against the data, but I cannot figure out logic which would be able to figure out whether or not "today" is schedule "Full" or schedule "CINC" Anyone willing to help an SA, in need of a long vacation away from backups?
Back to
Seekers of Perl Wisdom
|
|