solved ex6.2