From: Aidan Date: 2002-06-05T17:00:47+09:00 Subject: Re: Solving logic problems with Ruby Victor Manuel Reyes Viloria wrote: > > During my college days I experimented with a language called Prolog. > This language was suitable to solve logic problems. > Had anybody used Ruby to solve logic problems? Take a look at the AI section in the RAA. Peter Hickman's SIE, expert system's shell might be of interest. http://www.ruby-lang.org/en/raa-list.rhtml?name=SIE Prolog is a special case, since it intrinsically operates on as a theorem proving engine. There is however no reason why one could not implement a whole variety of specialized theorem engines in Ruby - just as one does with Lisp or C. Another approach that offers some interesting possibilities is to implement hybrid applications where imperative languages like Ruby are used to perform data manipulation & distribution tasks, under the direction of a logic engine implemented in Prolog. A kind of body/brain split. You write such a program quite easily on a Linux system. Install swi-prolog, or a similar implementation, and drive it from Ruby. Aidan