Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/operating-system/Shell.md
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ echo $length #输出:5
echo $length2 #输出:5
# 输出数组第三个元素
echo ${array[2]} #输出:3
unset array[1]# 删除下表为1的元素也就是删除第二个元素
unset array[1]# 删除下标为1的元素也就是删除第二个元素
for i in ${array[@]};do echo $i ;done # 遍历数组,输出: 1 3 4 5
unset arr_number; # 删除数组中的所有元素
for i in ${array[@]};do echo $i ;done # 遍历数组,数组元素为空,没有任何输出内容
Expand All @@ -283,7 +283,7 @@ for i in ${array[@]};do echo $i ;done # 遍历数组,数组元素为空,没

![算数运算符](http://my-blog-to-use.oss-cn-beijing.aliyuncs.com/18-11-22/4937342.jpg)

我以加法运算符做一个简单的示例:
我以加法运算符做一个简单的示例(注意:不是单引号,是反引号)

```shell
#!/bin/bash
Expand Down