There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult. C.A.R. Hoare
Write a program to flatten the linked list into singly linked list. The linked list may contain many list with two-dimensional array. The program should convert to singly linked list.
Nested list of elements: [1, [2, [3, 4]], [5, 6, 7], 8, [[9, 10]]] After remove flat list: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]