[snake] implementing snake game