Hi,

This is embarrassing.

All I want to do is read the content of a simple 10 line .txt file
into an array
and print out the lines, and I just can't seem to get it to work!
/*
$target = "D:\testfile.txt";
open NEWBIE, "<"$target";
@arr = <WAWA>;
foreach $line (@arr) {
print "$line\n";
}
close(NEWBIE)
*/


Running this in Primalscript does not result in anything other than
the
Exit code: 0 , 0000h message.

Is it ok to reference the full path in the 2nd arg to 'open'?

Would appreciate any help..while I wait for my copies of
Learning Perl and Programming Perl to arrive!

Thanks,
Stuart




-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to