some minor syntax / style improvements

Thanks for putting this tutorial together! I made a few minor corrections before sharing this with my students:

- Assignment to variables without declaration (game, snake, i, etc...)
- Inconsistent spacing around operators / control statements
- Adding the getKey function to the global Object prototype is kind of arbitrary and modifying browser natives is generally discouraged. I didn't see any reason this couldn't just be a normal function declaration