The Camel book seems to say that splice will only remove or change elements and move them *down* if necessary.
You must think I'm a raging newb, but I gotta admit, I've never used splice. Thanks, I'll check it out! Barry Brevik > -----Original Message----- > From: perl-win32-users-boun...@listserv.activestate.com > [mailto:perl-win32-users-boun...@listserv.activestate.com] On > Behalf Of Tobias Hoellrich > Sent: Wednesday, September 07, 2011 10:41 AM > To: Barry Brevik > Cc: perl-win32-users@listserv.ActiveState.com > Subject: RE: Help with array > > perldoc -f splice > > Cheers - Tobias > > -----Original Message----- > From: perl-win32-users-boun...@listserv.activestate.com > [mailto:perl-win32-users-boun...@listserv.activestate.com] On > Behalf Of Barry Brevik > Sent: Wednesday, September 07, 2011 11:38 AM > To: perl-win32-users@listserv.ActiveState.com > Subject: Help with array > > I've issued perldoc-q array and Googled for an answer and > found nothing. > > Let's say I have an array with a number of elements in it, > and I want to insert an element somewhere in the body of the > array, and move all remaining elements up (or to the right, > or higher) by one. > > Sure, I could use a loop, but is there a cleaner, more > Perl-ish way of doing it? > > Barry Brevik > > _______________________________________________ > Perl-Win32-Users mailing list > Perl-Win32-Users@listserv.ActiveState.com > To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs > > _______________________________________________ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs