#!/usr/bin/perl -w

$file_to_parse = shift;
$output = shift;

open(INPUT, $file_to_parse) or die("Could not open input file");
open(OUTPUT, ">$output") or die("Could not open output file");

while(<INPUT>){
    my($lineString) = $_;
    chomp($lineString);
    
    if($lineString =~ m/;; Query time:/){
        @tokens = split(/ /, $lineString);
        print OUTPUT "$tokens[3]\n";
    }
}

