Help for this page
sub myfunc { my ($ts, $interval) = @_; ... $minute = substr($ts, 10, 2); return $interval * int($minute / $interval); }