bash: array - Replace and element in an array.
-
Take into account the main readme for this section. README first.
An array called planet.
$ declare -a planet=(earth wind fire)
Replace element 1 from wind to air.
$ echo "${planet[@]/wind/air}" earth air fire
© Lightnetics 2024