Added duration calculation to print-out - still NPEs but returns correct result.