Help for this page

Select Code to Download


  1. or download this
    open my $fh, "<", $infile or die "error opening '$infile':$?";
    
  2. or download this
        if ( m/^(\d{2}:\d{2}:\d{2},\d+)\s\-\-\>\s(\d{2}:\d{2}:\d{2},\d+)/g
    + ) {
    
  3. or download this
        my @elems = split(':', $time);
        my $seconds = pop @elems;
        my $minutes = pop @elems;
        my $hours   = pop @elems;
    
  4. or download this
        my ( $hours, $minutes, $seconds ) = split /:/, $time;
    
  5. or download this
        # force to numerical
        $hours += 0; $minutes += 0; $seconds += 0;
    
  6. or download this
        my $seconds = sprintf( "%02.3f", ( ( $sectime - ( $hours * 3600 ) 
    +) - ( $minutes * 60 )) );