length/2

length(? L,? S)*

Unify the well-defined list L with its length. The procedure can be used to find the length of a pre-defined list, or to build a list of length S.