How to convert a chunks result to a two-dimensional array

forkit forkit at gmail.com
Sat Jan 15 03:20:28 UTC 2022


On Saturday, 15 January 2022 at 02:41:08 UTC, Paul Backus wrote:
>
> import std.algorithm: map;
> import std.array: array;
>
> int[][] arrayOfArrays = iota(1, 16).chunks(5).map!array.array;

oh. thanks!

also it seems I reposted the same question (didn't realise this 
one got posted)


More information about the Digitalmars-d-learn mailing list