Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread John W. Krahn
Ing. Branislav Gerzo wrote: JupiterHost.Net [JN], on Thursday, April 28, 2005 at 09:11 (-0500) contributed this to our collective wisdom: (really beginners) could think @a will empty array, which is not true. JN yes it is true, they are both empty lists: @a will not empty array, here it is: my @a

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread DBSMITH
Subject Re: REGEXP removing - il- - -b-f and - il- - - - f

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread Ing. Branislav Gerzo
[EMAIL PROTECTED] [D], on Friday, April 29, 2005 at 08:43 (-0400) thoughtfully wrote the following: DSo which is safer more ideal to use : || , or I think or is better - it makes perl language more readable for beginners. -- How do you protect mail on web? I use http://www.2pu.net [Join the

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread DBSMITH
AM Subject Re: REGEXP removing - il- - -b-f and - il- - - - f

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread Ing. Branislav Gerzo
[EMAIL PROTECTED] [D], on Friday, April 29, 2005 at 09:30 (-0400) wrote about: DOc well, I am trying to get beyond a beginner as I have doing Perl for 3 DOc years now so is your answer still the same? I think really good programmers write nice readable programs (scripts), so begginers should

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread Peter Rabbitson
I think really good programmers write nice readable programs (scripts), so begginers should understand that sooner. I think, that's why better using or instead ||. Come-on guys! Read your mails. John Krahn spent the time to write a wonderful explanation why || simply DOES NOT WORK when used

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread John Doe
Am Freitag, 29. April 2005 14.43 schrieb [EMAIL PROTECTED]: So which is safer more ideal to use : || , or Derek B. Smith OhioHealth IT UNIX / TSM / EDM Teams [...] The only difference between || and or is the precedence, and the precedence of = lies between them. To my understanding, in

RE: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread Manav Mathur
|-Original Message- |From: Ing. Branislav Gerzo [mailto:[EMAIL PROTECTED] |Sent: Friday, April 29, 2005 7:11 PM |To: beginners@perl.org |Subject: Re: REGEXP removing - il- - -b-f and - il- - - - f | | |[EMAIL PROTECTED] [D], on Friday, April 29, 2005 at 09:30 (-0400) |wrote about

RE: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread Larsen, Errin M HMMA/IT
-Original Message- From: John Doe [mailto:[EMAIL PROTECTED] Sent: Friday, April 29, 2005 8:50 AM To: beginners@perl.org Subject: Re: REGEXP removing - il- - -b-f and - il- - - - f Am Freitag, 29. April 2005 14.43 schrieb [EMAIL PROTECTED]: So which is safer more ideal to use

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread Jay Savage
On 4/28/05, John W. Krahn [EMAIL PROTECTED] wrote: Jay Savage wrote: On 4/27/05, John W. Krahn [EMAIL PROTECTED] wrote: Jay Savage wrote: 4 open (V4, samcmd v4 2\1 | ) || die unable to open pipe... Broken?$!; Don't do this. the precedence of || is too high. your code attempts

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread John W. Krahn
Peter Rabbitson wrote: I think really good programmers write nice readable programs (scripts), so begginers should understand that sooner. I think, that's why better using or instead ||. Come-on guys! Read your mails. John Krahn spent the time to write a wonderful explanation why || simply DOES

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-29 Thread John W. Krahn
Jay Savage wrote: [big snip] I will admit that my response to OP didn't take into account that, in his particular case, the argument to open was a literal and || was being evaluated at compile time. But the fact remains that it is simply and demonstrably not true that open will never attempt to

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread John W. Krahn
[EMAIL PROTECTED] wrote: I will answer and ask all questions in one email! k. 8foreach (V4) { Is there any good reason to slurp the entire file into memory? What would you suggest? I want to read the entire file via a filehandle. I have plenty of system memory, therefore why not? Why

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread Ing. Branislav Gerzo
John W. Krahn [JWK], on Wednesday, April 27, 2005 at 17:29 (-0700) has on mind: JWK my @a; creates the lexical variable @a at compile time and since it has just JWK been created it will be empty. my @a = (); creates the variable during JWK compilation but the assignment (IIRC) has to be done at

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread Ing. Branislav Gerzo
[EMAIL PROTECTED] [D], on Wednesday, April 27, 2005 at 12:55 (-0400) wrote the following: D But I do not understand what the (split)[-1] is saying? please explain. it gets last splitted value from the list. (split)[0] #get the first splitted value (split)[0,1] #get first and second splitted

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread JupiterHost.Net
(really beginners) could think @a will empty array, which is not true. yes it is true, they are both empty lists: perl -mstrict -MData::Dumper -we 'my @x;my @y = ();print Dumper [EMAIL PROTECTED], [EMAIL PROTECTED];' Show me any difference in @x and @y :) Its about when and how its handled and

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread Ing. Branislav Gerzo
JupiterHost.Net [JN], on Thursday, April 28, 2005 at 09:11 (-0500) contributed this to our collective wisdom: (really beginners) could think @a will empty array, which is not true. JN yes it is true, they are both empty lists: @a will not empty array, here it is: my @a = q{foo bar}; @a;

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread JupiterHost.Net
Ing. Branislav Gerzo wrote: JupiterHost.Net [JN], on Thursday, April 28, 2005 at 09:11 (-0500) contributed this to our collective wisdom: (really beginners) could think @a will empty array, which is not true. JN yes it is true, they are both empty lists: @a will not empty array, here it is: I

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread Jay Savage
On 4/27/05, John W. Krahn [EMAIL PROTECTED] wrote: Jay Savage wrote: 4 open (V4, samcmd v4 2\1 | ) || die unable to open pipe... Broken?$!; Don't do this. the precedence of || is too high. your code attempts to open a pipe, and if it can't, then it attempts to open die... and

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-28 Thread John W. Krahn
Jay Savage wrote: On 4/27/05, John W. Krahn [EMAIL PROTECTED] wrote: Jay Savage wrote: 4 open (V4, samcmd v4 2\1 | ) || die unable to open pipe... Broken?$!; Don't do this. the precedence of || is too high. your code attempts to open a pipe, and if it can't, then it attempts to open die...

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread DBSMITH
yes I agree I was a little ambiguous... I was in a hurry. sorry. Anyway here is my updated code. and here is a sample output: My goal is to get all F01 which I am but I am having issues capturing all of these values into my array. When I run the I get the data I want to see which is just the F01

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread JupiterHost.Net
[EMAIL PROTECTED] wrote: yes I agree I was a little ambiguous... I was in a hurry. sorry. Anyway Then do it at a later time and do it right, I imagine most all of us are busy also :) here is my updated code. and here is a sample output: My goal is to get all F01 which I am but I am having

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread Ing. Branislav Gerzo
JupiterHost.Net [JN], on Wednesday, April 27, 2005 at 08:15 (-0500) thoughtfully wrote the following: 5 my @fa =(); 6 my @ha =(); JN my @fa; JN my @ha; JN the = () isn't necessary and doesn't keep you from getting uninitialized JN value warnings like you think it does, thats only scalars. I

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread Jay Savage
On 4/27/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: yes I agree I was a little ambiguous... I was in a hurry. sorry. Anyway here is my updated code. and here is a sample output: My goal is to get all F01 which I am but I am having issues capturing all of these values into my array. When I

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread Ing. Branislav Gerzo
Jay Savage [JS], on Wednesday, April 27, 2005 at 10:26 (-0400) thoughtfully wrote the following: JS If all you want is the last column, this is a really long way to go about it. JS while (V4) { JS print (split)[7]; JS print \n; JS } (split)[-1] is better, not ? -- How do

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread JupiterHost.Net
If all you want is the last column, this is a really long way to go about it. while (V4) { print (split)[7]; print \n; } I think that won't work due to some rows formatted like so: 2005/01/20 15:39 17 2% -il-o-b- - - - - sg F01000 unless that was typo? In that case 7

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread JupiterHost.Net
Ing. Branislav Gerzo wrote: JupiterHost.Net [JN], on Wednesday, April 27, 2005 at 08:15 (-0500) thoughtfully wrote the following: 5 my @fa =(); 6 my @ha =(); JN my @fa; JN my @ha; JN the = () isn't necessary and doesn't keep you from getting uninitialized JN value warnings like you think it

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread Jay Savage
On 4/27/05, Ing. Branislav Gerzo [EMAIL PROTECTED] wrote: Jay Savage [JS], on Wednesday, April 27, 2005 at 10:26 (-0400) thoughtfully wrote the following: JS If all you want is the last column, this is a really long way to go about it. JS while (V4) { JS print (split)[7]; JS

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread Jay Savage
On 4/27/05, JupiterHost.Net [EMAIL PROTECTED] wrote: If all you want is the last column, this is a really long way to go about it. while (V4) { print (split)[7]; print \n; } I think that won't work due to some rows formatted like so: 2005/01/20 15:39 17

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread JupiterHost.Net
I was assuming it was a typo/email munge, and that the command he pipes actually produces consistent output. That may be a faulty assumption on my part. YOu know what they say about assumptions In Its hard to say Derek doesn't give us much to work with :) general, though, when parsing log files

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread DBSMITH
cc AM Subject Re: REGEXP removing - il- - -b-f and - il- - - - f

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread DBSMITH
Re: REGEXP removing - il- - -b-f and - il- - - - f

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread JupiterHost.Net
[EMAIL PROTECTED] wrote: yes that is true, [5,6,7] need to be typed otherwise all entries are not Yes what is true? Please reply inline. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/ http://learn.perl.org/first-response

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread DBSMITH
Subject Re: REGEXP removing - il- - -b-f and - il- - - - f

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread DBSMITH
PM Subject Re: REGEXP removing - il- - -b-f and - il- - - - f

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread John W. Krahn
[EMAIL PROTECTED] wrote: yes I agree I was a little ambiguous... I was in a hurry. sorry. Anyway here is my updated code. and here is a sample output: My goal is to get all F01 which I am but I am having issues capturing all of these values into my array. When I run the I get the data I want to

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread Ing. Branislav Gerzo
JupiterHost.Net [JN], on Wednesday, April 27, 2005 at 10:23 (-0500) thinks about: JN No its not, you can if you want but it pointless: I read it somewhere (it was perl cookbook/learning perl from o'reilly maybe). Always declare my @a = ( ); And here is why, if I remember correctly - if you

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread JupiterHost.Net
You do realize that the characters 'F', '0' and '1' are included in the character class \w which split() is removing? :-) yeah I realized that typo too late :), I meant \s not \w but then plain old my @tmp = split; is even better :) -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread John W. Krahn
Ing. Branislav Gerzo wrote: JupiterHost.Net [JN], on Wednesday, April 27, 2005 at 10:23 (-0500) thinks about: JN No its not, you can if you want but it pointless: I read it somewhere (it was perl cookbook/learning perl from o'reilly maybe). Always declare my @a = ( ); And here is why, if I

Re: REGEXP removing - il- - -b-f and - il- - - - f

2005-04-27 Thread DBSMITH
Subject Re: REGEXP removing - il- - -b-f and - il- - - - f