in reply to Matching Sequential IP Addresses

Dru,
This sounds like a very fun problem. Unfortunately, I don't have time to work out a solution for you. Here is the algorithm I would start with:
my %class_c; for my $ip (keys %IPs) { my $class_c = get_class_c_from_ip($ip); my $integer = convert_quad_ip_to_int($ip); my $bit = $integer - first_integer_in_class_c($class_c); vec($class_c{$class_c}, $bit, 1) = 1; } for $network (keys %class_c) { print "$network\n" if all_bits_are_1($class_c{$network}); }

Sorry it doesn't imply map and sorry I left out all the interesting subs but it is often important to lay out the structure of a solution first. You can then ensure that you can make it work and refactor later.

Cheers - L~R