Finish Algorithms 6.2, 6.3