in reply to Why do i get an extra (duplicate) array element?-

Pleas post a complete program (and data) that demonstrates your problem. I cannot duplicate it.
use strict; use warnings; *IN = *DATA; my $row; my $val; while ( $row = <IN> ) { $val = substr( $row, 0, 1 ); my @tranAmount = substr( $row, 68, 17 ); foreach (@tranAmount) { print "$_\n"; } } __DATA__ 0 10 +.00000000000000 0 10 +.00000000000000 0 10 +.00000000000000 - -3 +0.0000000000000

OUTPUT:

10.00000000000000 10.00000000000000 10.00000000000000 -30.0000000000000

UPDATE: Corrected formatting tag

Bill