單項選擇題在shell腳本中,已知string="hasaki",請問echo ${string:1:3}將輸出什么內容?()

A.has
B.asa
C.hhh
D.aliakatong


您可能感興趣的試卷

你可能感興趣的試題

1.單項選擇題在shell腳本中,下面哪種方法可以獲得字符串變量string的長度?()

A.#{$string}
B.${#string}
C.${$string}
D.#{#string}

2.單項選擇題在shell腳本中,good是已知變量,下面哪種方法不可以實現(xiàn)字符串的拼接賦值?()

A.txt="I am "$good"vegetable!"
B.txt="I am ${good}vegetable!"
C.txt=’I am ’$good’vegetable!’
D.txt=’I am ${good}vegetable!’