Answers for "split sh string"

0

split sh string

#YOURSTRING="this_is_an_example"
#output:
#this
#is
#an
#example
for i in $(echo $YOURSTRING | tr "_" "\n")
do
	echo $i
done
Posted by: Guest on June-14-2021
1

split bash string

IN="[email protected];[email protected]"
arrIN=(${IN//;/ })
Posted by: Guest on April-29-2020

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language