shell脚本标准输出赋值给变量

方案一:bash #!/bin/bash string="hello world!" result=$(echo $string) echo $result 方案二:code #!/bin/bash string="hello world!" result=`echo $string` echo $result
相关文章
相关标签/搜索