in reply to Deleting Files

You're providing unlink with an incomplete path i.e missing $data. A quick map should rememdy this
unlink map "$dir\\$_", @file == @file or die "ack: $!";
Oh and the .*$ in your regex is extraneous as you're matching zero or more of anything to the end of the string, which will always match.
HTH

_________
broquaint

update: fixed bug (added == @file to die appropriately), thanks to liz