Categorizing Ranges

Jonathan M Davis via Digitalmars-d digitalmars-d at puremagic.com
Wed Oct 7 11:18:42 PDT 2015


On Wednesday, 7 October 2015 at 15:06:55 UTC, Mike Parker wrote:
> I'm looking for ideas on how to label the ranges returned from 
> take and drop. Some examples of what I think are appropriate 
> categories for other types of ranges:
>
> Generative - iota, recurrence, sequence
> Compositional - chain, roundRobin, transposed
> Iterative - retro, stride, lockstep
> XXX - take, drop
>
> What to put into the XXX? I first thought of "Greedy", but that 
> has an association with "greedy algorithms" that I don't really 
> like. That led to "Selfish", but it's admittedly not that 
> appropriate. Beyond that, I'm stuck. Any and all ideas 
> appreciated.

If it were just take, then maybe "bounding" would work, and I 
guess that _technically_ that works with drop as well, but it 
seems kind of off to talk about bounding when the bounds are 
everything _but_ a small number of elements.

- Jonathan M Davis


More information about the Digitalmars-d mailing list