in reply to How can I write this in a "simpler" way?

I just found this:
while(defined $line=<STDIN>) { so something }

Is this the way to go?

Replies are listed 'Best First'.
Re^2: How can I write this in a "simpler" way?
by choroba (Cardinal) on Feb 11, 2014 at 23:37 UTC
    It still uses the <> operator, with STDIN as the operand.
    لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ
      Yeah, his "problem" is not to use the <> like the general way, <STDIN> is acceptable.