Finish exercise6.5