Completed code for first part

No enhancements