perl -lnE 's/\w+(\w) (.*)/\$1+=$2/e}{say $d*($n-$p)'

