Skip to content

Latest commit

 

History

History
36 lines (27 loc) · 2.15 KB

README.md

File metadata and controls

36 lines (27 loc) · 2.15 KB

The Very Hungry Caterpillar 🍊🍏🍑🍒🍎🐛

Hungry rule-based BattleSnake written in C++. Knows how to avoid walls, other snakes and find the closest food. Made for testing and educational purposes. Public. Can pass a few challenges and has reached Gold medal on Global Arena.

Gold medal on Global Arena

This BattleSnake is based on the web-server provided with the unofficial C++ BattleSnake engine.

The Very Hungry Caterpillar is a simple battlesnake that knows how to

  • Avoid walls
  • Avoid other snakes
  • Find the closest food

You can build and run it as is, if you want. There are even Docker files included to make deployment easier. You can fork and modify it to make it smarter. But I really hope that you:

  • Carefully read this doc and source code.
  • Understand how it works.
  • Implement your own battlesnake from scratch.
  • Use your favorite language. C++ isn't the best choice if you just learn to code, really.

Why?

The Very Hungry Caterpillar isn't very strong battlesnake. Its older brothers Hungry Caterpillar and Smart Caterpillar show much better results in arenas. So why was it created?

  • To test the server provided with the unofficial C++ BattleSnake engine.
  • To show how to use the server in your battlesnakes.
  • To educate you about basic BattleSnake strategies and useful algorithms.

Contents