Challenge: Sometimes we've already computed seen-hashes.
%seenAl = ( abel => 2, baker => 1, camera => 1,
delta => 1, edward => 1, fargo => 1,
golfer => 1 );
%seenBob = ( baker => 1, camera => 1,
delta => 2, edward => 1, fargo => 1,
golfer => 1, hilton => 1 );
Since List::Compare internally transforms lists into seen-hashes, why can't we just pass the seen-hashes directly?
Response: Now we can.
$lcsh = List::Compare->new(\%seenAl, \%seenBob);
@intersection = $lcsh->get_intersection;
Previous | Back to start of show | Next |
Slide: 12 pass_seenhash | © 2004-18 James E. Keenan |