in reply to Re: Concatenating Array elements
in thread Concatenating Array elements

On splice; the third index tells perl how many elements to remove. Thus this effectively does what you want

Just want to add to the lineup above that after the splice, index 8 still exists and now holds value 10 and so on (whereas previously index n held value n+1, it now holds n+2 for n = 8..15

Or am I just too tired? :P

Replies are listed 'Best First'.
Re^3: Concatenating Array elements
by soonix (Chancellor) on Aug 20, 2014 at 07:13 UTC
    Or am I just too tired? :P

    I think so.

    What would you expect to happen with the indices, if you insert elements into the Array (fourth Parameter of splice)?