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