shell获取字符串长度

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

  

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