navred
02-09-2005, 09:44 PM
Hi,
Is it possible to write grammar for If-else in Prolog?
If yes, Please can some one give me a rough idea of the grammar.
Thanks,
SUDHA
4Dvertex
03-11-2005, 02:50 AM
Hi,
Is it possible to write grammar for If-else in Prolog?
If yes, Please can some one give me a rough idea of the grammar.
Thanks,
SUDHA
15948
What grammar?have and as "," or "if" as :-
words parsing W in the tree
"A tall man loves this clever woman" ;)
W
NP (Nominal phrase) VP (Verbal phrase)
domains
list symbol*.
predicates
sentence(list,list).
noun_phrase(list,list).
verb_phrase(list,list).
adj_noun(list,list).
.........................
clauses
sentence(List,Rem):-
...........................
Goal: sentence(W). -> true
that all
good parsing
vBulletin, Copyright ©2000-2009, Jelsoft Enterprises Ltd.