small func recognizes [] and [X].

This commit is contained in:
Simon Forman 2019-08-19 22:02:06 -07:00
parent b59e70f96d
commit 6e646c012f
1 changed files with 4 additions and 0 deletions

View File

@ -114,6 +114,10 @@ func(bool, [_|S], [true|S]).
func(sqrt, [A|S], [B|S]) :- B is sqrt(A).
func(small, [[_]|S], [ true|S]).
func(small, [ []|S], [ true|S]).
func(small, [ X|S], [false|S]) :- X \= [_], X \= [].
/*
Combinators