Help for this page

Select Code to Download


  1. or download this
    my %count = ();
    foreach my $device (@current_list, @temp_devicelist) {
        $count{$device}++;
    }
    
  2. or download this
    my %count;
    # ...
    ...
    my @difference = grep { $count{$_} == 1 } keys %count;
    my @intersect  = grep { $count{$_} == 2 } keys %count;
    my @union      = keys %count;
    
  3. or download this
    print "Difference:\n";
    print "$_\n" for @difference;
    ...
    print "$_\n" for @intersect;
    print "Union:\n";
    print "$_\n" for @union;