Finished Task 3. Cleaned up some previous code.