in reply to Re: script not working
in thread script not working
Or even better, use strict; as shown here:
#! perl -w use strict; my @lines1= <DATA>; print "number of lines = $#lines1\n"; my $fivefirstfile1= substr($lines1[2], 0, 5); print "Five first characters are: $fivefprot1\n"; __DATA__ First line of the file. Second line of the file. Third line of the file. Fourth line of the file. Fifth line of the file. Sixth line of the file.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: script not working
by 2teez (Vicar) on Dec 27, 2012 at 12:25 UTC | |
by Lotus1 (Vicar) on Dec 27, 2012 at 18:23 UTC |
In Section
Seekers of Perl Wisdom