Skip to content

C++ program similar to N queen’s problem, so as to save baby lizards from eating each other in a zoo having trees in between using Breadth First Search, Depth First Search and Simulated Annealing.

License

Notifications You must be signed in to change notification settings

SimarRajput/BabyLizard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BabyLizard

I am a zookeeper in the reptile house. One of our rare South Pacific Tufted Wizzo lizards (Tufticus Wizzocus) has just had several babies. Our job is to find a place to put each baby lizard in a nursery. However, there is a catch, the baby lizards have very long tongues. A baby lizard can shoot out its tongue and eat any other baby lizard before I have time to save it. As such, I want to make sure that no baby lizard can eat another baby lizard in the nursery (burp). For each baby lizard, I can place them in one spot on a grid. From there, they can shoot out their tongue up, down, left, right and diagonally as well. Their tongues are very long and can reach to the edge of the nursery from any location.

In addition to baby lizards, our nursery may have some trees planted in it. Our lizards cannot shoot their tongues through the trees nor can I move a lizard into the same place as a tree. As such, a tree will block any lizard from eating another lizard if it is in the path. Additionally, the tree will block me from moving the lizard to that location.

About

C++ program similar to N queen’s problem, so as to save baby lizards from eating each other in a zoo having trees in between using Breadth First Search, Depth First Search and Simulated Annealing.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages