The important distinction with chomp is that it removes $/ from the end of each element in the list passed to it (nothing happens if an element is not terminated with $/).
Chop removes the last character without regard to what the character is - chop always alters a non-empty element.
Note in particular that line end differences between file systems have been papered over by this stage and the default value for $/ is \n (which may or may not be a line feed character; you don't need to know). Neither chop nor chomp know or care about file system line end differences.
In reply to Re^2: Problem with <STDIN>
by GrandFather
in thread Problem with <STDIN>
by sivaramanm
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |