Why is std.algorithm so complicated to use?

Daniel Murphy yebblies at nospamgmail.com
Tue Jul 10 09:42:17 PDT 2012


"Jacob Carlborg" <doob at me.com> wrote in message 
news:jthlpf$2pnb$1 at digitalmars.com...
>
> Can't "map" and "filter" return a random-access range if that's what they 
> receive?
>
map can, and does.
filter cannot, because it doesn't know which element is number 4 until it 
knows if element 3 is included or not. 




More information about the Digitalmars-d mailing list