in reply to How do I join two files side by side?
print while <>; [download]
And you call it as:
./joinfiles x y > xy [download]
Originally posted as a Categorized Answer.