Prolog add to list if element is not equal to string -


i trying create list of pairs have non-null guard element.

get_only_guarded(l) :-     guard \= null,     findall([s,d],transition(s,d,_,guard,_),l). 

this ive tried doesnt seem work. correct way?

use dif(guard,null) instead. handle (\=)/2 care!


Comments

Popular posts from this blog

angularjs - Showing an empty as first option in select tag -

python - argument 2 to map() must support iteration -

How to wrap some text in a rectangle in QML? -