Add common prefix to bash array elements Edit Delete array bash element elements prefix sh shell variable a=(help verbose) echo ${opts[@]/#/--};