use strict; use warnings; my $current = `date`; print "Current date and time is $current"; print `date -d "1 day ago"`; print `date -d "1 week ago"`; print `date -d "1 month ago"`; print `date -d "1 year ago"`;