shell习题170920-给文档增加内容

新朋友请点上方shell习题170920-给文档增加内容
 蓝字“阿铭linux”关注

在文本文档1.txt第5行后面增加如下内容:

# This is a test file.

# Test insert line into this file.

答案明日公布。

习题170919-打印数字==参考答案==

#!/bin/bash

read -p "请输入您想要暂停的数字:" number_1

for i in `seq 1 $number_1`;

do

        echo $i

done

read -p "是否继续输入数字?" a

if [ $a == "yes" ];then

        read -p "请继续输入您想要暂停的数字:" number_2

        number_3=$[$number_1+1]

        if [ $number_2 -gt $number_1 ];then

                for h in `seq $number_3 $number_2`;

                do

                        echo $h

                done

        else

                echo "输入数字错误,请输入大于的数字!"

        fi

else

        exit

fi



- END -

出品 | 阿铭linux

shell习题170920-给文档增加内容

私人微信:81677956  验证:公众号   

shell习题170920-给文档增加内容

提升自己,才是世界上最稳健的投资

shell习题170920-给文档增加内容