in reply to The While Loop is Breaking My Variables

It works for me, input and output is:

$ perl bhcesl.pl a b c 1 2 3 a-1b-2c -3 ------------------------------
etc.

I think that you may not be expecting to read STDIN from the command line. The wait for input could be mistaken for an infinite loop that wasn't printing anything.

The first two lines after "perl . . ." are the inputs, "a\tb\tc\n" and "1\t2\t3\n". Those newlines are seen in the output. chomp is the cure for that.

After Compline,
Zaxo