perl -MData::Dumper -we "my $k; while($k=shift @ARGV and $v = shift @ARGV ){$h{$k}=$v};$h{$k}= undef unless exists $h{$k}; print Dumper \%h " 1 a 2 b ODD $VAR1 = { '1' => 'a', 'ODD' => undef, '2' => 'b' };