$filename = "MyJScript01.txt"; push(@filenames,$filename); $filenumber = 1; #variable to track the filenames format: MyJscript#.txt where # is a number open (OUT,">$filename"); print OUT "\n"; close OUT; (at the end I do stuff with the files created)...