in reply to deleting elements of one array from another
From your example code (ignoring the [assumed typo] syntax error), it seems like you don't necessarily want to remove the array element but, rather, want to delete any occurrences of $in in each element of @db. If that's the case, just use a nested loop...
foreach my $db (@db) { foreach my $in (@in) { $db =~ s/$in//g; } }
But if you actually want to remove any elements of @db that exactly match one of the elements of @in, then use one of the previous suggestions. :)
bbfu
Black flowers blossum
Fearless on my breath
|
|---|