Remove the prompting from inside the loop. Then do this: Each time a file is found that has a "last modified" time of greater than three days, push $file into @found. At the end of the loop, if @found contains entries, then prompt the user if he wants them deleted. If the response is yes, then "unlink @found;".
Dave
In reply to Re: one user prompt instead of many
by davido
in thread one user prompt instead of many
by AngusScrimm
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |