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 run time. The end JWK> result is the same but the assignment makes it a tiny bit slower (not enough JWK> to really worry about.) yes, I thought same too, thanks for nice explanation. My habits say - always use my @a = ( ); I also think it looks "better". One (really beginners) could think "@a" will empty array, which is not true. for $| I didn't know, $| = 1 is maybe more "perlish" and $|++ is more AWKard. But that doesn't matter, good to know they _always_ produce the same effect. -- How do you protect mail on web? I use http://www.2pu.net ["He delivered them into the hands of spoilers." -- Judges 2:14] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>