in reply to string to array

I don't recommend doing this (other answers were safer) but for the sake of completeness:

perl -le 'my $aref = eval "[1,2]"; print join("+", @{$aref})' 1+2