shell获取字符串长度

string="abcd"
echo ${#string} #输出 4

  

posted @ 2018-09-18 20:11  anobscureretreat  阅读(263)  评论(0编辑  收藏  举报