Domanda di colloquio di Brillio

1 simple DSA question was asked to flat a nested array without using flat function.