Skip to content
Discussion options

You must be logged in to vote

Apparently, you entered as --> [] on the top level like so:

?- use_module(library(dcgs)).
   true.
?- as --> [].
   error(existence_error(procedure,(-->)/2),(-->)/2).   % that's fine
?- [user].
as --> [].
as --> "a", as.

?- phrase(as,L).
   L = []
;  L = "a"
;  L = "aa"
;  L = "aaa"
;  L = "aaaa"
;  ... .

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by d-gaston
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants