Use the arrow keys to move. I learnt the code in school There are some bugs and I am attempting to fix them. To win- collect all the food If you lose all of your lives you lose The snakes are the enemies.
Thanks to @Emmie-Cat for doing a bug fix, it was a massive help