in reply to count lines, bottom to top

If you had "use warnings" in your code, then Perl would tell you that you have opened a filehandle (USF) for writing and are then trying to read from it.

"use strict" and "use warnings" allow Perl to help you find the problems in your code. It's crazy to try and write code without them.

--
<http://dave.org.uk>

"The first rule of Perl club is you do not talk about Perl club."
-- Chip Salzenberg