Homework from my Python class