By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,848 Members | 1,380 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,848 IT Pros & Developers. It's quick & easy.

DATE in Perl

P: 48
Hi
I need to get ten previous year and month from the current date....
Is there any perl module which I can use for the same..
For eg if the date is 2008-07-10
I nned to get the following output

2008-06
2008-05
2008-04
2008-03
2008-02
2008-01
2007-12
2007-11
2007-10
2007-09

So a total count of 10 entries as above .Can you please give some pointers to solve the same....

Thanks in Advance
Mar 13 '08 #1
Share this Question
Share on Google+
1 Reply


numberwhun
Expert Mod 2.5K+
P: 3,503
Hi
I need to get ten previous year and month from the current date....
Is there any perl module which I can use for the same..
For eg if the date is 2008-07-10
I nned to get the following output

2008-06
2008-05
2008-04
2008-03
2008-02
2008-01
2007-12
2007-11
2007-10
2007-09

So a total count of 10 entries as above .Can you please give some pointers to solve the same....

Thanks in Advance
I don't know of a module that would do specifically that, but you could definitely write some code to do it. Why not try writing it and if you get stuck, then post the code here (in code tags) and we will help you.

Regards,

Jeff
Mar 13 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.