Retrieves the current size of a term vector.
tv_size/2 unifies Size with the size of the term vector Vector.
Vector object (term vector) Size var or integer
tv_create(V),
tv_size(V, InitialSize),
tv_add(V, one),
tv_add(V, two),
tv_size(V, FinalSize).
->
InitialSize = 0
FinalSize = 2
This predicate is not part of the ISO-Prolog Standard.
| scroll to top |
|