x=$(sed 's/*/ */g;s/\// \//g' $1)
while [[ "$x" != ?(-)+([0-9]) ]];do
x=$(xargs -I{} -d' ' -n1 bash -c '{ echo "{}";echo "{}"|bc 2>/dev/null;}|tail -n1|tr "\n" " "'<<<"$x "|sed -r 's/ $//;s/(.) /\1/g')
done
echo "$x"
