Python Error fixing

Simply copy pastes from the professors code. The reason it was not
working before is because the code was not actually the exact same.