admin 管理员组文章数量: 887032
2024年2月20日发(作者:stripe登录)
read srcechoecho -n "destination fold:"read descp -arf $src $desif $?; thenecho "copy sucessful!"elseecho " copy fail"fi;;2)echo -n "the file to be renamed:"read srcechoecho -n "the new file:"read desmv $src $desif $?; thenecho "rename sucessful!"elseecho " rename fail"fi;;3)echo -n "the file to be removed:"read srcrm -rf $srcif $?; thenecho "remove sucessful!"elseecho " remove fail"fi;;4)echo -n "the file to be found:"read srcfind $HOME -name $src;;
echo "************************************************"echoecho -n " select:"read choiceechocase $choice in1)echo -n "source file:"read srcechoecho -n "destination fold:"read descp -arf $src $desif $?; thenecho "copy sucessful!"elseecho " copy fail"fi;;2)echo -n "the file to be renamed:"read srcechoecho -n "the new file:"read desmv $src $desif $?; thenecho "rename sucessful!"elseecho " rename fail"fi;;3)echo -n "the file to be removed:"read srcrm -rf $srcif $?; then2.
参考程序:#!/bin/shi=1while [ $i -le 50 ]douserdel -r stud${i}i=$(($i+1 ))doneecho "remove sucessful!"elseecho " remove fail"fi;;4)echo -n "the file to be found:"read srcfind $HOME -name $src;;5) exit;;*) echo "Invalid option";;esacdone2.参考程序:#!/bin/shi=1while [ $i -le 50 ]douserdel -r stud${i}i=$(($i+1 ))done3.参考程序:#! /bin/sh –for i in 1 2 3 4 5 6 7 8 9dofor j in 1 2 3 4 5 6 7 8 9do
if ( test $j -le $i ) thenecho -ne `expr $i * $j` "t"elseechobreakfidonedon
版权声明:本文标题:linux期末考试试卷及答案 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.freenas.com.cn/free/1708386859h522164.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论