Cold Help System: Programming: ColdC Reference Manual: Functions: List: listgraft()


LIST listgraft(LIST list1, INTEGER pos, LIST list2)

This function is similar to the splice operator and insert(), except it grafts a list into another list, rather than inserting an element at a point in the list. It will take the list specified by list2 and place each element in that list into the list specified by list1, starting at the position specified by pos. Example:

listgraft([1, 2, 3, 4, 5], 3, ["foo", "bar", "baz"])
=> [1, 2, "foo", "bar", "baz", 3, 4, 5]


delete() | insert() | join() | listgraft() | listlen() | replace() | setadd() | setremove() | sublist() | union() | listidx()


the Cold Dark