1.子串:
1.子串切片
[root@shell ~]# name="I am majunnan" [root@shell ~]# echo ${name:2:2} # 从第二个字符串后开始,截两个字符串 am [root@shell ~]# echo ${name:2:4} # 从第二个字符串后开始,截四个字符串 am m
——————————————————————————————————————————————————————————————————————————
无敌小马爱学习
标签:...,shell,name,am,字符串,root,Day From: https://www.cnblogs.com/junnan/p/18554945