@ARGV = <$LOGDIR/*.log>; #### my @fileList = glob($LOGDIR/*.log); while (@fileList) { ... } #### s/L//;