Logtalk 2.15.2 files.

git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@812 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
pmoura
2003-04-02 13:57:50 +00:00
parent 8509b82b18
commit f1b417f1c3
103 changed files with 744 additions and 100 deletions

View File

@@ -0,0 +1,35 @@
=================================================================
Logtalk - Object oriented extension to Prolog
Release 2.15.2
Copyright (c) 1998-2003 Paulo Moura. All Rights Reserved.
=================================================================
% DCG rules implementing a simple calculator:
| ?- calculator::parse("1+2-3*4", Result).
Result = -9
yes
% recognizing gramatically correct sentences
| ?- sentence::parse([the, girl, likes, the, boy], Result).
Result = true
yes
| ?- sentence::parse([the, girl, scares, the, boy], Result).
Result = false
yes
% generating parse trees for sentences
| ?- parsetree::parse([the, girl, likes, the, boy], Tree).
Tree = Tree = s(np(d(the), n(girl)), vp(v(likes), np(d(the), n(boy))))
yes