Some code learned from lessons on Codecademy