On Jan 2, [EMAIL PROTECTED] said: >That's right. But let me add my 5cents to it. If you decide to use the >construct "while ( <MYFILE> )..." then it better be >while( defined(<MYFILE>) ) { >//... >}
Not so. First, doing defined(<MYFILE>) does not store a line in $_ -- for that, you'd need defined($_ = <MYFILE>). Second, while (<FH>) automatically becomes while (defined($_ = <FH>)). See the perlsyn documentation. -- Jeff "japhy" Pinyan [EMAIL PROTECTED] http://www.pobox.com/~japhy/ RPI Acacia brother #734 http://www.perlmonks.org/ http://www.cpan.org/ ** Look for "Regular Expressions in Perl" published by Manning, in 2002 ** <stu> what does y/// stand for? <tenderpuss> why, yansliterate of course. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]