Skip to main content

All Questions

Filter by
Sorted by
Tagged with
12 votes
1 answer
2k views

Flatten an array of integers in Python

The goal is to flatten an array of nested arrays of integers. For example [1, [2], [3, [4]]] should return [1, 2, 3, 4] I'm ...
Nikolay Derkach's user avatar