in reply to stat and localtime

Beware the month's count starting at 0, and the year 0 = 1900
my ($seconds, $minutes, $hours, $day, $month, $year) = (localtime($fil +e))[0..5]; $month++; # starts counting with 0 $year += 1900; # years since 1900