in reply to Re^2: Recursive sub efficiencyin thread Recursive sub efficiency
Comment out your @files line, then @dirs should contain something. You can not call readdir two times like that.