in reply to subtract one array from another

You could also use hashes for this:
my %hash1 = ( 1 => '1', 83 => '1', 90 => '1', 120 => '1', 140 => '1', 300 => '1' ); my @array = ('83', '140'); for (@array){ delete $hash1{$_}; }
Now keys(%hash1) only contains the entries you want. you could do more checking or other processing in your loop if you wanted. You could even be 'safer' like this:
for (@array){ delete $hash1{$_} if exists $hash1{$_}; }
but it is a little silly since the delete will only do anything if the entry exists in the hash anyway.

Chad.