if (exists $bptoifIndex{$bp}) { $mactobp{$mac} = $bptoifIndex{$bp}; print "$mac matches with $bptoifIndex{$bp}.\n" if $debug; } else { warn "$mac / $bp does not have an entry in %bptoifIndex\n"; }