Can these two steps be combined into one (I need to remove the last 2 elements and the first element)? I thought I could do -2,3 but it doesn't work that way.
splice(@array,-2,2);
splice(@array,0,1);
Can these two be combined?
my @array = $telnet->waitfor('/]/');
my @newarray = split /\n/, $array[0];
I tried
@newarray = split(/\n/, $telnet->waitfor('/]/')); (And a few variations but everything is coming back as a 1).
Thanks in advance as always!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
![[noevil] [noevil] [noevil]](/data/assets/smilies/noevil.gif)
Travis - Those who say it cannot be done are usually interrupted by someone else doing it; Give the wrong symptoms, get the wrong solutions;
splice(@array,-2,2);
splice(@array,0,1);
Can these two be combined?
my @array = $telnet->waitfor('/]/');
my @newarray = split /\n/, $array[0];
I tried
@newarray = split(/\n/, $telnet->waitfor('/]/')); (And a few variations but everything is coming back as a 1).
Thanks in advance as always!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
![[noevil] [noevil] [noevil]](/data/assets/smilies/noevil.gif)
Travis - Those who say it cannot be done are usually interrupted by someone else doing it; Give the wrong symptoms, get the wrong solutions;