in reply to Re: perl time conversion (seconds)
in thread perl time conversion
sub time_converter { if ($#_ != 0) { print "not correct amount of vars passed"; return 0; } my @timearray = split (':', $_[0]); unless ($#timearray == 2) { return 0; } return (($timearray[0]*60*60)+($timearray[1]*60)+($timearray[2])); }
|
|---|