Tree Breadth-First in Prolog

Just to follow up for others looking for more details on this concept.

In “The Craft of Prolog” by Richard A. O`Keefe (WorldCat) is section 3.10 Pruning Alternative Solutions which goes into this in more detail.

If you are learning Prolog for the first time either on your own or in a class you should have a copy of this book handy and if you have a problem you have no idea how to solve or feel that it could be better than read the relevant part of the book. I personally read sections of the book every few months for just such problems.

Remember that most school libraries (at least in the U.S.A) have inter-library loan so there is no reason not to have this if you are a student.

Also note that with the WorldCat link you can add a location and when it is supplied you will get a location of the all the libraries that have the book that are near your location. :smiley:

This is one of those concepts that took me a while to fully understand, but now cuts are my friend and not my enemy or some concept that seems hazy.