Path: utzoo!utgpu!water!watmath!clyde!rutgers!sri-unix!quintus!ok From: ok@quintus.UUCP (Richard A. O'Keefe) Newsgroups: comp.lang.prolog Subject: Triangle puzzle Message-ID: <651@cresswell.quintus.UUCP> Date: 15 Feb 88 05:03:00 GMT Organization: Quintus Computer Systems, Mountain View, CA Lines: 16 To follow up my "review" of "Prolog Programming in Depth", I thought I'd take one of their examples and show how to revise it, making it cleaner & faster & so on. The one I picked was "TRIANGLE.PRO", pp 234-237. I got 1/3rd of the way through typing it in, and found it too painful to continue. Has anyone got a machine-readable version of this program they could send me? They report that the Arity Prolog *interpreter* takes "a little over a minute", but this doesn't mean a great deal, especially as there appear to be two typos in the jump/3 table. For what it's worth: jump(5,8,13). should be jump(5,8,12). and jump(13,21,11). should be jump(13,12,11). My version in compiled Quintus Prolog on a SUN-3/50 takes 0.75 seconds, but this doesn't mean much.