How do you know that @data_file keeps values from previous use? @data_file is lexical to the CleanFiles() subroutine. Each time you call CleanFiles() you're going to get a fresh @data_file (that's how my works). Are you sure about what you're seeing?
|Replies are listed 'Best First'.|
Re^2: Why does the array not reset each time I call the function?
by tuxy94 (Initiate) on Apr 02, 2008 at 13:51 UTC
Here is the output of the script: