Dave Thacker wrote:
I want to print a line of 50 "-"'s to a file. This is my non-working syntax.
#!/usr/bin/perl
open (FOO, "foo.out");
print FOO repeat(50,"-");
close FOO;
Undefined subroutine &main::repeat called at ./foo.pl line 4.
Whats the correct syntax for doing this?
print FOO '-' x 50;
John
--
Perl isn't a toolbox, but a small machine shop where you
can special-order certain sorts of tools at low cost and
in short order. -- Larry Wall
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/