$dir = "D:\books"; @output = `dir $dir /B /S`; #### $dir = "/some/path"; @output = `find $dir`;