resubmission of assignment #4