Categorizing Ranges

2015-10-07 Thread Mike Parker via Digitalmars-d
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,

Re: Categorizing Ranges

2015-10-07 Thread Big Daddy via Digitalmars-d
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, roun

Re: Categorizing Ranges

2015-10-07 Thread Jonathan M Davis via Digitalmars-d
On Wednesday, 7 October 2015 at 15:13:17 UTC, Big Daddy wrote: 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: Gen

Re: Categorizing Ranges

2015-10-07 Thread Andrea Fontana via Digitalmars-d
On Wednesday, 7 October 2015 at 15:43:44 UTC, Ali Çehreli wrote: On 10/07/2015 08:06 AM, Mike Parker wrote: Something like shortening, minimizing? Ali Slicing?

Re: Categorizing Ranges

2015-10-07 Thread drug via Digitalmars-d
On 07.10.2015 18:06, 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 Iterativ

Re: Categorizing Ranges

2015-10-07 Thread Ali Çehreli via Digitalmars-d
On 10/07/2015 08:06 AM, 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 Itera

Re: Categorizing Ranges

2015-10-07 Thread Jonathan M Davis via Digitalmars-d
On Wednesday, 7 October 2015 at 15:46:00 UTC, Andrea Fontana wrote: On Wednesday, 7 October 2015 at 15:43:44 UTC, Ali Çehreli wrote: On 10/07/2015 08:06 AM, Mike Parker wrote: Something like shortening, minimizing? Ali Slicing? Similar, but that's already a pretty overloaded term, and neith

Re: Categorizing Ranges

2015-10-07 Thread Gerald Jansen via Digitalmars-d
On Wednesday, 7 October 2015 at 15:46:00 UTC, Andrea Fontana wrote: On Wednesday, 7 October 2015 at 15:43:44 UTC, Ali Çehreli wrote: On 10/07/2015 08:06 AM, Mike Parker wrote: Something like shortening, minimizing? Slicing? Partitioning?

Re: Categorizing Ranges

2015-10-07 Thread Mike Parker via Digitalmars-d
On Wednesday, 7 October 2015 at 15:43:44 UTC, Ali Çehreli wrote: Something like shortening, minimizing? Ali How about reductive?

Re: Categorizing Ranges

2015-10-07 Thread DLangLearner via Digitalmars-d
On Wednesday, 7 October 2015 at 16:15:13 UTC, Mike Parker wrote: On Wednesday, 7 October 2015 at 15:43:44 UTC, Ali Çehreli wrote: Something like shortening, minimizing? Ali How about reductive? subtractive

Re: Categorizing Ranges

2015-10-07 Thread Meta via Digitalmars-d
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, roun

Re: Categorizing Ranges

2015-10-07 Thread Jonathan M Davis via Digitalmars-d
On Wednesday, 7 October 2015 at 16:54:00 UTC, Meta wrote: 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: Generati

Re: Categorizing Ranges

2015-10-07 Thread H. S. Teoh via Digitalmars-d
On Wed, Oct 07, 2015 at 05:15:45PM +, Jonathan M Davis via Digitalmars-d wrote: > On Wednesday, 7 October 2015 at 16:54:00 UTC, Meta wrote: > >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.

Re: Categorizing Ranges

2015-10-07 Thread Ali Çehreli via Digitalmars-d
On 10/07/2015 09:15 AM, Mike Parker wrote: On Wednesday, 7 October 2015 at 15:43:44 UTC, Ali Çehreli wrote: Something like shortening, minimizing? Ali How about reductive? That's what I had in mind when I started thesaurusing for the other two. :) Ali

Re: Categorizing Ranges

2015-10-07 Thread Meta via Digitalmars-d
On Wednesday, 7 October 2015 at 17:15:47 UTC, Jonathan M Davis wrote: Except that take doesn't mutate its function argument, and drop only does if the range is a reference type. So, they really aren't mutating algorithms. - Jonathan M Davis Yeah, true. Partitioning or Isolating, something al

Re: Categorizing Ranges

2015-10-07 Thread The Great one via Digitalmars-d
On Wednesday, 7 October 2015 at 18:09:51 UTC, Meta wrote: On Wednesday, 7 October 2015 at 17:15:47 UTC, Jonathan M Davis wrote: Except that take doesn't mutate its function argument, and drop only does if the range is a reference type. So, they really aren't mutating algorithms. - Jonathan M

Re: Categorizing Ranges

2015-10-07 Thread Jonathan M Davis via Digitalmars-d
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, roun

Re: Categorizing Ranges

2015-10-07 Thread qznc via Digitalmars-d
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, roun

Re: Categorizing Ranges

2015-10-07 Thread Mike Parker via Digitalmars-d
On Wednesday, 7 October 2015 at 15:06:55 UTC, Mike Parker wrote: What to put into the XXX? Thanks for the brainstorming session everyone. I'm on a deadline so I need to pick something and go with it. This thread has simplified things for me.

Re: Categorizing Ranges

2015-10-07 Thread Mike Parker via Digitalmars-d
On Wednesday, 7 October 2015 at 18:26:29 UTC, qznc wrote: Selective Although, then stride fits better into Selective than into Iterative. On the other hand, iterative seems not that fitting to me. lockstep might also be Compositional. I actually agree with you about iterative, but I hadn't

Re: Categorizing Ranges

2015-10-09 Thread Per Nordlöw via Digitalmars-d
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, roun

Re: Categorizing Ranges

2015-10-09 Thread Per Nordlöw via Digitalmars-d
On Friday, 9 October 2015 at 10:01:47 UTC, Per Nordlöw wrote: I've Googled a bit on this topic, say: "algorithm visualization" "Software Visualization" seems to be the correct research term.

Re: Categorizing Ranges

2015-10-09 Thread Mike Parker via Digitalmars-d
On Friday, 9 October 2015 at 10:01:47 UTC, Per Nordlöw wrote: I'm guessing you're thinking about categorizing the list at http://dlang.org/phobos/std_range.html , right? ;) That would, IMHO, be a nice usability/discoverability improvement, especially for new users! :) This is for the "

Re: Categorizing Ranges

2015-10-09 Thread Jonathan M Davis via Digitalmars-d
On Friday, 9 October 2015 at 16:08:58 UTC, Mike Parker wrote: This is for the "Learning D" book I'm currently doing revisions on. In the chapter on std.range and std.algorithm, there was an imbalance with the latter being neatly categorized into the different modules. It looked odd having the s

Re: Categorizing Ranges

2015-10-10 Thread Joseph Rushton Wakeling via Digitalmars-d
On Wednesday, 7 October 2015 at 15:39:03 UTC, Jonathan M Davis wrote: Eager is far more general. Also, while the drop* functions are eager, the take* functions are not. I don't recall the precise details of these particular ranges off the top of my head (away from computer so can't easily chec