Flatten range of ranges
Ali Çehreli
acehreli at yahoo.com
Thu May 6 09:24:53 PDT 2010
Ali Çehreli wrote:
> new to d wrote:
>> Is there any function in phobos that does something like that:
>>
>> auto a = [[1,2],[3,4]];
>> assert(equals(flatten(a), [1,2,3,4]));
>>
>> I am just learning D and ca't find anything like that in the docs.
>
> How about chain:
>
> http://digitalmars.com/d/2.0/phobos/std_range.html#chain
Sorry, of course that's not what you wanted... :(
Ali
More information about the Digitalmars-d-learn
mailing list