February 22, 2018
Ubuntu:shell脚本运行异常, bash和dash的区别, sh和bash的区别, bash、dash与zsh shell, source、sh、bash、./执行脚本的区别
今天想运行一下非常简单的代码:test.sh
#!/bin/bash
str="Learn to Split a String in Bash Scripting"
IFS=' ' # space is set as delimiter
read -ra ADDR <<< "$str" # str is read into an array as tokens separated by IFS
for i in "${ADDR[@]}"; do # access each element of