for my $ip ( keys %files ) { zip \@{ $files{$ip} } => "$ip.zip" or die "zip failed: $ZipError\n"; }