13.13. Summary

Logic programming lets you model a problem in terms of relations. Thinking about the relations in a problem is fundamentally different from thinking about objects. To show this difference, you can try asking seasoned Java developers this question: How would you model, in Java, the fact that Aristotle is taller than Plato if you do not know either man's height?

In Logikus, the answer is

taller(aristotle, plato) 

In Java, the answer is more elusive, and many developers find that they simply cannot arrive at a solution. Interestingly, for such stymied developers, it simplifies the problem to modify the relationship so that Aristotle manages Plato.

There are no problems Logikus can solve that Java cannot solve. There are, however, ...

Get Building Parsers with Java™ now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.