Ex1.7

Solved half of 1.7