Two worked examples of logic programming in Prolog, the N-Queens problem and Tic-Tac-Toe, from the declarative specification to the program, with the techniques they need: generate and test, the closed-world assumption, assert and retract, terms built at run time.
