From the hub, tagged: "maplist"
Functional Prolog: Map, Filter and Reduce
Prolog programs have both logical and procedural meanings. In this post we'll take a look at procedural ideas more commonly associated with functional programming than Prolog, namely: map, filter and reduce (foldl and foldr). We'll code them and then query them.
Graph Traversal for Problem Solving
This post is external to PrologHubAn example of using depth first and breadth first searches (written to be nearly identical to highlight the subtle difference between a stack and a queue) to solve three common puzzles commonly used as examples in AI textbooks.
Various ways to iterate in Prolog
This post is external to PrologHubThis is a list of simple examples, mainly created for my own reference, on the numerous ways of list processing in Prolog. My original title was six ways to iterate in Prolog, but it's reached 11 and still counting.