answers for 1st part of assignment