ex6 - almost done