homework 3 exercise 1 and 2
end of homework 3 exercise 2