in reply to Re^2: How to perform single operation to each line in file
in thread How to perform single operation to each line in file

$/ tells readline or <> to read the whole file. foreach does not read anything, it just iterates a list. You give it a one member list: it contains the whole file as its only member.
لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ