solution for assignment one