Run 3.6.pl like this from the command line:

perl 3.6.pl <lower.txt >upper.txt