Re: Newbie that needs some help

2004-02-22 Thread John W. Krahn
Owen wrote: > > On Sat, 21 Feb 2004 21:23:13 -0600 > Perl Mail User <[EMAIL PROTECTED]> wrote: > > I think you need to change > > > foreach ($line) { > > @lines = $line; > > to > > push(@lines,$line); > > Your foreach loop is in the inner most loop, so your @lines is only

Re: Newbie that needs some help

2004-02-22 Thread John W. Krahn
Perl Mail User wrote: > > Hello All, Hello, > I have a basic question, I am new to perl, and I would like to try > and get a basic question answered, if possible. I have a file with > about 63 lines in it, I am running it through a basic perl program > that reads every line and prints it to the

Re: Newbie that needs some help

2004-02-21 Thread Owen
On Sat, 21 Feb 2004 21:23:13 -0600 Perl Mail User <[EMAIL PROTECTED]> wrote: > Hello All, > > I have a basic question, I am new to perl, and I would like to try > and get a basic question answered, if possible. I have a file with > about 63 lines in it, I am running it through a basic perl pro

Re: Newbie that needs some help

2004-02-21 Thread WilliamGunther
I would probably write it like this (Although, I'm not sure what that :58 is about): open(FILE, "file1.txt") or die "Can not open file. ", $!, "\n"; @lines = grep { /:58/ } ; So you can understand and learn, let me just tell you you're mistakes. open(FILE, "file1.txt") or die "Can not open fil

Newbie that needs some help

2004-02-21 Thread Perl Mail User
Hello All, I have a basic question, I am new to perl, and I would like to try and get a basic question answered, if possible. I have a file with about 63 lines in it, I am running it through a basic perl program that reads every line and prints it to the screen. I am trying to get the output