Get the latest tech news
Four integers are enough to write a Snake Game
A snake written in 4 integers
After not implementing a game of snake in ages, I’ve decided to do my best today, but with some strange and absurd limitations in mind, you know, to spice up things: Because there’s no standard C-way of interacting with the keyboard, I will have to rely on curses, so if you want to compile the program, make sure you have the lib installed on your system. Unfortunately, curses uses additional memory by itself, but let’s be honest, hacking with arcane escape chars and low level system functions is not fun, and certainly not something that I am willing to try by myself.
Or read this on Hacker News