This is part of a series of fun little programs I write to learn rust:
Have you ever wanted to watch your computer play snake in a somewhat clumsy fashion? Here you go!
cargo run and enjoy! 🐍
You can choose the decision algorithm the snake uses via commandline flags. The available options are:
--random(default): The snake chooses a random (possible) direction for every step--greedy: The snake selects the (possible) direction which brings her closest to the food in the next step--angle: If the food is in the same column as the snake, she goes down. Otherwise, she goes right.
Use --help for more information.