in reply to about separator

You can combine
print $counter; $counter++;
into the single line
print $counter++;
because the ++ does a post-increment -- the current value is output, then the counter is incremented.

--t. alex

"Of course, you realize that this means war." -- Bugs Bunny.