Shared by Timothy Boronczyk on his blog: http://zaemis.blogspot.com/2010/07/learning-prolog.html