Question

Do you happen to know where can I find a list of prolog problems/exercises which involves DCG so that I can understand better this concept?

I have read some specifications regarding it, but the best way to learn it is to practice with it.

Thanks!

Was it helpful?

Solution

Here is a pretty good place to start http://www.scism.lsbu.ac.uk/inmandw/tutorials/nlp/. It begins with talking about language and then shows you ways of implementing it in Prolog.

It's good to start learning by creating programs that following strict language rules. A popular example set by Universities is creating parsers to accept valid blazons, because there is little ambiguity in this. You can search online for ways of creating valid blazons. The actual term for devising blazons is called heraldry.

Hope that helps!

OTHER TIPS

Check http://www.learnprolognow.org/. This actually has a chapter about DCG (Ch. 7). The exercises can be found here: http://cs.union.edu/~striegnk/learn-prolog-now/html/node62.html#sec.l7.exercises, but are actually also on the webpage.

Good luck!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top