in reply to Re: Writing in reverse
in thread Writing in reverse

You fell into the same trap as chromatic in that you only read the first line of the file. Either localize $/ to undef or use my @file1 = <$fh1>

Other then that though, this is very slick and you use a much better way of scoping the file handle.