There are closed list which end with `[]`

and open list which end with a variable, e.g.

Closed list AKA list

```
?- write_term([a,b,c],[dotlists(true)]).
.(a,.(b,.(c,[])))
true.
```

Open list AKA Partial list

```
?- write_term([a,b|T],[dotlists(true)]).
.(a,.(b,_7990))
true.
```

Then there are difference list, e.g.

`[1,2,3,4]-[3,4]`

or

`[1,2|T]-T`

or

`[1,2,3,4|T]-[3,4|T]`

```
?- write_term([1,2,3,4],[dotlists(true)]),
write_term(" - ",[]),
write_term([3,4],[dotlists(true)]).
.(1,.(2,.(3,.(4,[])))) - .(3,.(4,[]))
true.
?- write_term([1,2|T],[dotlists(true)]),
write_term(" - ",[]),
write_term(T,[dotlists(true)]).
.(1,.(2,_4594)) - _4594
true.
?- write_term([1,2,3,4|T],[dotlists(true)]),
write_term(" - ",[]),
write_term([3,4|T],[dotlists(true)]).
.(1,.(2,.(3,.(4,_6812)))) - .(3,.(4,_6812))
true.
```

Did I make a mistake anywhere?

**EDIT**

The purpose of this question was