updated the Assignement 2

the two functions have  been written