I want to make a nested array and flatten it at run-time like this.

auto nestedArray = [1, 2, [3, 4], 5];

auto flattenedArray = myFun(nestedArray);

writeln(flattenedArray);   // => [1, 2, 3, 4, 5]


How can I do this in D?

Please help me out!

Reply via email to