2

[SunOs] /opt # sh
[\h] \w \$ read -a array <<< "1 2 3";echo ${array[1]}
syntax error: `<' unexpected

バッシュで

[SunOs] ~ # bash
[SunOs] ~ # read -a array <<< "1 2 3";echo ${array[1]}
2

「sh」シェルでエラーが発生する理由、私は SunOS 5.10 Generic_147440-10 を使用しています

4

2 に答える 2