Ex3 completed

The code for ex3 is in place. All working as tested.