fork(1) download
  1. #!/usr/bin/perl
  2.  
  3. use strict;
  4. use warnings;
  5.  
  6. use Data::Dumper;
  7.  
  8. printf "Perl version is v%vd\n", $^V;
  9.  
  10. my %hash = (
  11. one => 1,
  12. two => 2,
  13. three => 3,
  14. );
  15.  
  16. my %results = delete @hash{qw(one two)};
  17. print Dumper(\%results);
  18.  
Success #stdin #stdout 0.02s 6032KB
stdin
Standard input is empty
stdout
Perl version is v5.24.1
$VAR1 = {
          '1' => 2
        };