This commit is contained in:
Mark Thom
2019-04-25 20:11:34 -06:00
parent b07a19fc47
commit 9b93c33491
2 changed files with 2 additions and 2 deletions

View File

@@ -13,7 +13,7 @@ length(Xs, N) :-
N >= 0, !,
'$skip_max_list'(M, N, Xs, Xs0),
( Xs0 == [] -> N = M
; var(Xs0) -> R is N-M, nl, length_rundown(Xs0, R)).
; var(Xs0) -> R is N-M, length_rundown(Xs0, R)).
length(_, N) :-
integer(N), !,
throw(error(domain_error(not_less_than_zero, N), length/2)).