I read an array from another script. This array needs to put " " around all array members since some members are empty.
in_file=./data
vector=($(./readdata.sh 0 $in_file))
for index in ${!vector[@]}
do
echo ${vector[index]}
done
The problem is that I have quotations around each output line and I want to get rid of them.
"red"
"blue"
"green"
""
"white"
"black"
must change to:
red
blue
green
white
black
I look for a method which does not use awk, tr, sed or any other pipeline based way. I just want to solve with using native ways such as using parenthesis, different punctuations, ....
sedsed." "around members for this purpose. avoid putting it around members in the original script is much easier.