Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: find date given day weekday and a range of months

by poj (Parson)
on Aug 22, 2014 at 19:47 UTC ( #1098371=note: print w/ replies, xml ) Need Help??


in reply to find date given day weekday and a range of months

#!perl use strict; use Time::Piece; my $day = 28; my $weekday = 'Thu'; my $year = '2014'; my @months = ('Aug', 'Sep', 'Oct'); for my $mth (@months){ my $t = Time::Piece->strptime("$day-$mth-$year","%d-%b-%Y"); print $t->ymd."\n" if $t->wdayname eq $weekday; }
poj
Comment on Re: find date given day weekday and a range of months
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1098371]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (8)
As of 2016-04-30 01:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    :nehw tseb si esrever ni gnitirW







    Results (441 votes). Check out past polls.