revised to print times for several algorithms -KL