# Build an array. Each element of the array is a reference # to a two-element array consisting of a Net::Netmask object # and a city name my @blocks; while () { my ($block, $city) = split /\|/; push @blocks, [Net::Netmask->new($block), $city]; }