use strict; use Time::localtime; ########################################################## # date_to_seconds subroutine sub date_to_seconds{ my $date = shift(@_); my ($year, $month, $day) = split(/-/, $date); $month--; return timelocal(0,0,0, $day, $month, $year); } ##########################################################