This function takes a list and replaces any lists contained within that list with the individual items from those lists.
Type
NUMERIC
Arguments
Type
Meaning
1
LIST
the list to be "flattened"
Evaluation
For each item in the input list, if the item is not a list, it is appended to the answer list, if it is a list, then it is flattened and then all of its items are appended to the answer list in turn.