in reply to memorizing files and then removing the unnecessary ones
my %myhash=map{$_ => 1}@old_arr ; @new_arr=grep{!$myhash{$_}}@new_arr; [download]