Add a logic for snake for avoiding its own tale
New logic for avoiding

Actually, it doesn't work correctly. I'll fix it at home.