solved exercise:9.6