http://www.perlmonks.org?node_id=1011357


in reply to $/ usage

If you were expecting the $/="\n"; at the end of your one-liner to do something, that's your problem. That step doesn't do anything.

The undef $/; at the beginning does make sure that all the data in your list file gets slurped into $text, so when you do print $text; you should see the full content of the list, in its original form (as stored in the file).

Did you want to see something different from that?