Write a function,
flattenArray(), that takes in a 2-dimensional array, flattens it into a 1-dimensional array, and returns it. You can assume that you will only be given one or two-dimensional arrays
flattenArray([1, 2, [3, 4, 5], 6, [7, 8], 9]) should return
[1, 2, 3, 4, 5, 6, 7, 8, 9].