Version: 1.5#118 (2000/4/19, 18:13:43 CEST)
Version of last change: 1.5#41 (2000/2/4, 13:34:24 CET)
This module provides a set of predicates for list processing.
lists):- use_module(library(lists)).
nonsingle/1,
append/3,
reverse/2,
reverse/3,
delete/3,
select/3,
length/2,
nth/3,
add_after/4,
add_before/4,
dlist/3,
list_concat/2,
list_insert/2,
insert_last/3,
contains_ro/2,
contains1/2,
nocontainsx/2,
last/2,
list_lookup/3,
list_lookup/4,
intset_insert/3,
intset_delete/3,
intset_in/2,
intset_sequence/3,
intersection/3,
union/3,
difference/3,
equal_lists/2,
list_to_list_of_lists/2,
powerset/2.
list1/2,
sublist/2,
subordlist/2.
lists)
Usage: nonsingle(X)
X is not a singleton.
Usage: append(Xs,Ys,Zs)
Zs is Ys appended to Xs.
Usage: reverse(Xs,Ys)
Xs.
Xs is a list.
(basic_props:list/1)
Ys is a free variable.
(term_typing:var/1)
Xs is a list.
(basic_props:list/1)
Ys is a list.
(basic_props:list/1)
No further documentation available for this predicate.
Usage: delete(L1,E,L2)
L2 is L1 without the ocurrences of E.
Usage: select(X,Xs,Ys)
Xs and Ys have the same elements except for one occurrence of X.
Usage 1: length(L,N)
L.
L is a list.
(basic_props:list/1)
N is a free variable.
(term_typing:var/1)
L is a list.
(basic_props:list/1)
N is currently instantiated to an integer.
(term_typing:integer/1)
Usage 2: length(L,N)
L of length N.
L is a free variable.
(term_typing:var/1)
N is currently instantiated to an integer.
(term_typing:integer/1)
L is a list.
(basic_props:list/1)
N is currently instantiated to an integer.
(term_typing:integer/1)
Usage 3: length(L,N)
L is of length N.
L is a list.
(basic_props:list/1)
N is currently instantiated to an integer.
(term_typing:integer/1)
L is a list.
(basic_props:list/1)
N is currently instantiated to an integer.
(term_typing:integer/1)
nth(N,List,Elem)
N is the position in List of Elem. N counts from one.
Usage 1: nth(+int,?(list),?(term))
Elem and the Nth element of List.
Usage 2: nth(-(int),?(list),?(term))
Elem is in List. Positions are found in ascending order.
Usage: add_after(+L0,+E0,+E,-(L))
E after element E0 (or at end) to list L0 returning in L the new list (uses term comparison).
No further documentation available for this predicate.
Meta-predicate with arguments: list1(?,pred(1)).
Usage: list1(X,Y)
X is a list of Ys of at least one element.
Usage: dlist(List,DList,Tail)
List is the result of removing Tail from the end of DList (makes a difference list from a list).
Usage: list_concat(LL,L)
L is the concatenation of all the lists in LL.
LL is a list of lists.
(basic_props:list/2)
L is a list.
(basic_props:list/1)
Usage: list_insert(-(List),+Term)
Term to the end of List if there is no element in List identical to Term.
Usage: insert_last(+L0,+E,-(L))
E at end of list L0 returning L.
Usage:
No further documentation available for this predicate.
Usage: nocontainsx(L,X)
X is not identical to any element of L.
Usage: last(L,X)
X to incomplete (i.e., ended in a variable) list L.
No further documentation available for this predicate.
Usage: list_lookup(List,Functor,Key,Value)
Functor(Key,Value) pair in variable ended key-value pair list L or else add it at the end.
No further documentation available for this predicate.
No further documentation available for this predicate.
No further documentation available for this predicate.
No further documentation available for this predicate.
Usage: intersection(+List1,+List2,-(List))
List has the elements which are both in List1 and List2.
Usage: union(+List1,+List2,-(List))
List has the elements which are in List1 followed by the elements which are in List2 but not in List1.
Usage: difference(+List1,+List2,-(List))
List has the elements which are in List1 but not in List2.
Usage: sublist(List1,List2)
List2 contains all the elements of List1.
List2 is currently a term which is not a free variable.
(term_typing:nonvar/1)
Usage: subordlist(List1,List2)
List2 contains all the elements of List1 in the same order.
List2 is currently a term which is not a free variable.
(term_typing:nonvar/1)
Usage: equal_lists(+List1,+List2)
List1 has all the elements of List2, and vice versa.
Usage: list_to_list_of_lists(+List,-(LList))
LList is the list of one element lists with elements of List.
Usage: powerset(+List,-(LList))
LList is the powerset of List, i.e., the list of all lists which have elements of List. If List is ordered, LList and all its elements are ordered.
Go to the first, previous, next, last section, table of contents.