Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^2: Working Through An Array In Chunks

by Cody Pendant (Prior)
on Dec 06, 2004 at 22:43 UTC ( [id://412771]=note: print w/replies, xml ) Need Help??


in reply to Re: Working Through An Array In Chunks
in thread Working Through An Array In Chunks

Thanks, that was the kind of answer I really wanted. I always forget "splice" for some reason, or get it mixed up with "slice". Why is it called "splice"? The literal meaning of that word is something more like "join", surely? Maybe it's a kind of combination of "slice" and "pop"?


($_='kkvvttuubbooppuuiiffssqqffssmmiibbddllffss')
=~y~b-v~a-z~s; print
  • Comment on Re^2: Working Through An Array In Chunks

Replies are listed 'Best First'.
Re^3: Working Through An Array In Chunks
by Zed_Lopez (Chaplain) on Dec 07, 2004 at 01:42 UTC

    "splice" makes perfect sense when you're extracting middle elements from an array and thus splicing together the leading and trailing elements.

    It makes, um, a little less sense when you're using it just to remove elements from the head or tail (to be clear, I'm speaking only of the command's name, not of its appropriateness for the task.)

    Though you could argue, say, that you're splicing together array position 0 and the middle of the array when you're removing elements from the head...

      I get your point.

      Does the word in this context originate with Perl, or is it used in other languages as well? I want to write to Larry and ask.



      ($_='kkvvttuubbooppuuiiffssqqffssmmiibbddllffss')
      =~y~b-v~a-z~s; print

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://412771]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2024-04-20 16:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found