# assuming @i = map "name$_" 1..5 /(\S+)\s+(-?\d+(?:.\d+)?)/and$a{$1}=$2 for; push@o,exists$a{$_}?$a{$_}:999 for@i;