http://www.perlmonks.org?node_id=83778


in reply to Yesterday's or last month's date?

Definitely Date::Calc is the best choice...
You can find it on CPAN
1. Yesterday: Add_Delta_Days
($year, $month, $day) = Add_Delta_Days(Today(), -1);
2. What do You mean date of last month?
Check Days_in_Month($year, $month) and do a cycle for that :)