Problem 4 solution added. ~0.005 seconds running time.