Write flatten(nested) that turns a list of lists into one list: [[1,2],[3],[]] → [1,2,3].
flatten(nested)
[[1,2],[3],[]]
[1,2,3]
flatten([[1, 2], [3], []]) → [1, 2, 3]
flatten([]) → []
Submit runs 4 tests, including hidden edge cases.
Run your code to see the output here.