Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: "piping" functions

From: volker::nitsch::gmail::com at: 24-Nov-2005 3:12

On 11/24/05, Jean-Francois Allie <jf_allie-hotmail.com> wrote:
> > Graham, > > GC> "back tail series" returns the series one back from the end > > My understanding is that your statement isn't exactly correct since the > wholeseries is in fact returned even if you only see it starting from the > INDEX position. >
Graham said "the series", not "a copy of the series". He could be more verbose, "a reference to the series at the position one back from the end", but it means the same.
> >>b: [1 2 3 4] > == [1 2 3 4] > >>c: back tail b > == [4] > >>head? c > == false > >>index? c > == 4 > >>c: head c > == [1 2 3 4] > >>index? c > == 1 > > ... but if you do a copy then you do end up with a series that actualy > startsat the INDEX. > > >>d: copy back tail b > == [4] > >>head? d > == true > >>index? d > == 1 > > This isn't to be nitpicking, but to understand these functions. Right now, > with what I know, BACK TAIL B in this function: > > >>COPY/PART B BACK TAIL B > > doesn't return the same thing as in: > > >>BACK TAIL B > > why? >
Hard to understand what you do not understand, i hope i do it: The focus is here copy/part B back tail b not here: copy/part b BACK TAIL B copy B return a copy of the series on position b. copy/part B back tail b returns a copy of the series on the position b, but not upto end, but upto back tail b
> > Gabriele, > > >>Actually, INDEX? is not needed. > > >>>>b: [1 2 3 4] > >>== [1 2 3 4] > >>>>copy/part b back tail b > >>== [1 2 3] > > >>Regards, > >>Gabriele. > > Yes precisely, but how come this function works without INDEX? as in > Graham'sversion? > > cheers, > > JF > > -- > To unsubscribe from the list, just send an email to > lists at rebol.com with unsubscribe as the subject. >
-- -Volker Any problem in computer science can be solved with another layer of indirection. But that usually will create another problem. David Wheeler