Completed problem assignment 3