in reply to Re^2: Filehandle opened only for output error
in thread Filehandle opened only for output error
cheersuse strict; use Data::Dumper; open(FILE, "<", "file.in") || die "Error in : $!"; my @array = <FILE>; close FILE; print Dumper(\@array); file.in here i am , where are you, i am here and you also here
PS
try dumping the @lineas to check if the data is in the array. if it is then surely the problem is somewhere else.
use Data::Dumper; sub Take_Txt{ my $archivo = shift; open my $ARCHIVO, '>', $archivo or die $!; my @lineas = <$ARCHIVO>; close $ARCHIVO; shift(@lineas); die Dumper(\@lineas); return @lineas; }
|
|---|