in reply to Re: Read And modify a series
in thread Read And modify a series

my $a; $a = unshift(@array); while ($a == 1) $a = unshift(@array); if (defined($a)) unshift @array, $a;

The first two unshifts should be shifts. You've been advised plenty of times to test code before posting; the very least you could do is proofread it.