If the arrays don't contain duplicate elements:
$c{$_}++ foreach @a; $c{$_}++ foreach @b; @c = grep { $c{$_} != 2 } @a; @d = grep { $c{$_} != 2 } @b;
In reply to Re: Algorithm for cancelling common factors between two lists of multiplicands
by ikegami
in thread Algorithm for cancelling common factors between two lists of multiplicands
by BrowserUk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |