Appends the element to tail of the list.
The value to be appended.
The appended list.
const iter = toIterator(appendToTail(1)(singleton(4)));expect(iter.next()).toStrictEqual({ value: 4, done: false });expect(iter.next()).toStrictEqual({ value: 1, done: false });expect(iter.next()).toStrictEqual({ value: undefined, done: true }); Copy
const iter = toIterator(appendToTail(1)(singleton(4)));expect(iter.next()).toStrictEqual({ value: 4, done: false });expect(iter.next()).toStrictEqual({ value: 1, done: false });expect(iter.next()).toStrictEqual({ value: undefined, done: true });
Appends the element to tail of the list.