solution fot assignment 3