Question

Write a function that extracts all numbers from the given nested list?

Login to Submit

Examples

Input: [1, 2, [3, 4]]
Output: [1, 2, 3, 4]

Input: [[1, 2], 3, 4]
Output: [1, 2, 3, 4]

Input: [1, [2, [3, 4]]]
Output: [1, 2, 3, 4]