I have string contains a path
string=\"toto.titi.12.tata.2.abc.def\"
I want to extract only the numbers from this string.
To extrac
Using awk:
arr=( $(echo $string | awk -F "." '{print $3, $5}') ) num1=${arr[0]} num2=${arr[1]}