![]() |
|
laziness, impatience, and hubris | |
PerlMonks |
Re: Further On Down the Lineby BerntB (Deacon) |
on Apr 11, 2009 at 23:17 UTC ( [id://757065]=note: print w/replies, xml ) | Need Help?? |
Your problems are with basic open/read/write/close to files. The first parameter to open should not be the file name... it should be a file handle. It is better to split the second parameter in two. See this simple example:
It is much better to write small test programs to check things like this out. I personally use oneliners all the time, like this:
What you really need is a good first book. There is a review link at the top of this page, it is better to go there, but you won't go wrong with "Perl Cookbook". Otherwise, for a quick look, try the shell cmds: (There is also a nice website, perldoc.perl.org.) Edit: I'm thinking of trying out Devel::REPL instead of one-liners. It seems neat.
In Section
Seekers of Perl Wisdom
|
|